I am trying to make a plot essentially showing means and confidence intervals for several different variables, and I want to have multiple dashed lines separating them at certain points. See screenshot below:
The only thing I want to change is that I want "blank1" and "blank2" to actually show up as blank, i.e. no text/label in those spots. Currently I have my dataset set up so that there are two rows corresponding to the two blank spots, with missing means and bounds. The problem is that, if I try naming or formatting the variable name as " ", then they have the same name and so only one of the dashed lines shows up. Any suggestions as to how to accomplish what I'm aiming for?
With 9.40M3 (I did not check if this works with earlier releases) you can use a character format to do the same. Keep the unique values in the category variable (like "a" and "b"), and then use a character format to format these to blank. It is important to put the character format on the XAXIS VALUESFORMAT option. Putting the format on the data set variable will cause the formatted values of "a" and "b" to be merged as one category value.
Try setting one as a space and the second as a '09'x which is a tab?
Non breaking spaces 'A0'x (aka nbsp) can be used to create character strings that remain distinct and invisible.
A string with one nbsp or more nbsps can be used. Easy way to do this is to put a "." and a ".." in the column, then use translate() function to replace the "." with a 'A0'x.
https://blogs.sas.com/content/graphicallyspeaking/2012/09/03/doing-more-with-nbsp/
With 9.40M3 (I did not check if this works with earlier releases) you can use a character format to do the same. Keep the unique values in the category variable (like "a" and "b"), and then use a character format to format these to blank. It is important to put the character format on the XAXIS VALUESFORMAT option. Putting the format on the data set variable will cause the formatted values of "a" and "b" to be merged as one category value.
Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.
Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.