STRING REMOVE WHITESPACE
Remove the white space characters from a string.
The STRING REMOVE SPACES command can be used to remove spaces from a
string. This command will remove, in addition to spaces, the
non-printing characters (i.e., codes 0 to 32 and 127 in the ASCII
collating sequence). Currently, Dataplot only checks for characters
in the 0 - 127 range of the ASCII collating sequence.
LET <sout> = STRING REMOVE WHITESPACE <sorg>
where <sout> is the name of the resulting string;
and <sorg> is the name of the original string.
LET SOUT = STRING REMOVE WHITESPACE STIN
The name of the new string can be the same as the original
string. For example,
LET STR = STRING REMOVE WHITESPACE STR
In this case, STR will now contain the the string with all white
space characters removed rather than the original string.
The string on the right hand side of the equal sign must be a
previously existing string. That is, expressions are not allowed.
For example, the following will result in an error message
LET STOUT = STRING REMOVE WHITESPACE "a b c d"
you need to do
LET STRING SORG = a b c d
LET SOUT = STRING REMOVE SPACES SORG
The name on the left hand side of the equal sign may be a
previously existing string. However, if it is a previously
existing parameter, variable, or matrix name, an error will
be reported and the requested string will not be created.
The total number of characters that DATAPLOT can use for storing
functions and strings is set when DATAPLOT is built. The current
default (11/2008) is 50,000 characters. Previous versions may set
this limit at 1,000 or 10,000 characters. This limit applies to the
combined number of characters for all functions and strings.
let string stin = a b c d
let stout = string remove whitespace stin
print stin stout
The following output is returned
STIN --a b c d
NIST is an agency of the U.S.
Date created: 10/10/2018
Last updated: 10/10/2018
Please email comments on this WWW page to