xxformat_com
Barite | Level 11
Member since
01-03-2018
- 379 Posts
- 104 Likes Given
- 17 Solutions
- 31 Likes Received
This widget could not be displayed.
-
Latest posts by xxformat_com
Subject Views Posted 427 02-23-2025 12:09 PM 533 10-31-2024 01:24 PM 1417 09-29-2024 11:00 AM 1480 09-29-2024 04:58 AM 1540 09-29-2024 12:05 AM 895 09-28-2024 11:44 PM 902 09-28-2024 11:37 PM 998 09-28-2024 04:33 AM 709 09-19-2024 02:35 PM 827 09-15-2024 10:15 AM -
Activity Feed for xxformat_com
- Posted radar using GTL or proc sgplot ? on Graphics Programming. 02-23-2025 12:09 PM
- Liked How to remove the hyperlink from the title of TOC in PDF for renee_njc. 02-23-2025 09:17 AM
- Liked Re: Text Sentiment Analysis for LeliaM. 11-01-2024 04:10 PM
- Posted Text Sentiment Analysis on Graphics Programming. 10-31-2024 01:24 PM
- Liked Re: Appending datasets and identifying missing variables in the output for mkeintz. 10-04-2024 06:10 AM
- Liked Re: Appending datasets and identifying missing variables in the output for Tom. 10-04-2024 06:09 AM
- Liked Re: Appending datasets and identifying missing variables in the output for Patrick. 10-04-2024 06:09 AM
- Posted Re: Appending datasets and identifying missing variables in the output on SAS Programming. 09-29-2024 11:00 AM
- Posted Re: Appending datasets and identifying missing variables in the output on SAS Programming. 09-29-2024 04:58 AM
- Posted Appending datasets and identifying missing variables in the output on SAS Programming. 09-29-2024 12:05 AM
- Liked Re: Listing variables to print for FreelanceReinh. 09-28-2024 11:51 PM
- Posted Re: Listing variables to print on SAS Programming. 09-28-2024 11:44 PM
- Posted Re: Listing variables to print on SAS Programming. 09-28-2024 11:37 PM
- Posted Listing variables to print on SAS Programming. 09-28-2024 04:33 AM
- Posted Re: Hoy to size the symbol when keylegend type=markersymbol on Graphics Programming. 09-19-2024 02:35 PM
- Posted Re: Hoy to size the symbol when keylegend type=markersymbol on Graphics Programming. 09-15-2024 10:15 AM
- Posted Hoy to size the symbol when keylegend type=markersymbol on Graphics Programming. 09-14-2024 08:49 AM
- Liked Re: axistable - any example with name= for ballardw. 09-09-2024 10:41 AM
- Posted Re: proc sgplot: valuesformat= vs. variable format on Graphics Programming. 09-04-2024 08:50 AM
- Liked Re: proc sgplot: valuesformat= vs. variable format for Ksharp. 09-04-2024 07:35 AM
-
Posts I Liked
Subject Likes Author Latest Post 1 2 2 2 1 -
My Liked Posts
Subject Likes Posted 2 07-24-2024 08:29 AM 1 06-30-2023 04:11 AM 2 06-14-2023 03:56 AM 3 03-27-2023 09:49 AM 2 12-27-2022 07:08 AM
02-23-2025
12:09 PM
Hi,
Can radars be created with proc sgplot or GTL using SAS 9.4 or do we have to use the old procedure proc gradar?
... View more
10-31-2024
01:24 PM
Which graph procedure can be used to represent words frequency i.e. to have a representation like the one given by SAS Visual Analytics?
... View more
09-29-2024
11:00 AM
data a;
a='A';
b='B';
x=1;
y=1;
run;
data b;
a='A';
c='C';
x=2;
z=2;
run;
data z (drop=i j);
set a b;
array charvar {*} _character_;
array numvar {*} _numeric_;
do i=1 to dim(charvar);
if charvar{i} = ' ' then charvar{i}='/';
end;
do j=1 to dim(numvar);
if numvar{j} = . then numvar{j}=.A;
end;
run;
proc print data=z;
var a b c x y z;
run;
But I'm assuming there is an easier approach.
Actually, I added more data and an extra layer of difficulty after that in my code because any missing value of an existing variable should not be reported with / or .A
data a;
a='A';
b='B';
w=.;
x=1;
y=1;
run;
data b;
a='A';
c='C';
d=' ';
x=2;
z=2;
run;
At the end, my excel report changes the background of the cells only when the variables were not in the original datasets (my datasets are coming from .csv file I import) and I have an extra layer of probably unneeded complication using a loop for call define in proc report.
... View more
09-29-2024
04:58 AM
I used a set statement only.
The solution I've found is using arrays.
I'm just assuming that there is a better way of doing it.
... View more
09-29-2024
12:05 AM
Datasets to append can have different variables.
Sometimes, it can be useful to identify in the output dataset when values are missing before the variable was not in the original dataset.
data a;
a='A';
b='B';
x=1;
y=1;
run;
data b;
a='A';
c='C';
x=2;
z=2;
run;
How would you get a slash when the character variable was missing and a .A when the numeric variable was missing?
... View more
09-28-2024
11:44 PM
I like the two set statements.
Is there a specific reason for preferring a view over a dataset?
... View more
09-28-2024
11:37 PM
I agree about y: but it is just a demo example. But the question was about listing all the variables which are not starting with x as in real life, we either don't know the name of the variables in advance or the list is so long that automating is worth it.
... View more
09-28-2024
04:33 AM
As far as I know it is not possible to use "not" with <varname>: to list a series of variable not starting with.
In other words, it is not possible to do this:
data tmp;
x1=1;
x2=2;
y1=1;
y2=2;
run;
proc print data=tmp;
var not(x:) x:;
run;
We can still use a macro variable:
data tmp;
x1=1;
x2=2;
y1=1;
y2=2;
run;
proc sql noprint;
select name into: notx separated by ' '
from dictionary.columns
where libname='WORK' and
memname='TMP' and
upcase(name) not like 'X%';
quit;
proc print data=tmp;
var ¬x. x:;
run;
Would you have any other suggestion?
... View more
09-19-2024
02:35 PM
The swimmer plot is an example where type= option could be used in keylegend.
In this paper you can start to see that the code starts to get messy with so many scatter statement.
https://www.lexjansen.com/phuse-us/2018/dv/DV08.pdf
Here we have to keep in mind that programs have to be validated in clinical research and programmers don't really like validating other people programs.
So it is essentiel to have short effective and comprehensive code to facilitate the process.
The SAS system offers the opportunity to derive items from a specific symbol plotted on the graph. If we don't have any flexibility to define the symbol size, then the benefit of the feature is lost and we keep with old workaround.
... View more
09-15-2024
10:15 AM
As for multiple legenditem, it overloads the procedure when we could expect the size given in the wall to be reused. fill type have its options. I would expect something similar to be available for symbols.
... View more
09-14-2024
08:49 AM
The type= option of the keylegend statement allow to keep a subset of the symbol used on the graph.
In the example, a filled symbol is used. It is always possible to resize the rectangle in the legend using scale, fillheigh, fillaspact.
However it is not possible to use these options to resize the symbol. Is there any other option which could be used.
Note: An alternative solution would be to create a specific legenditem only for the symbol (no color).
But here I'm just checking on whether I have missed an option.
proc sgplot data=sashelp.class;
scatter x=weight y=height / filledoutlinedmarkers
markerfillattrs = (color = red)
markeroutlineattrs = (color = blue
thickness = 2)
markerattrs = (size = 30
symbol = DiamondFilled);
keylegend / position=right type=marker;
keylegend / position=right type=markercolor scale=;
keylegend / position=right type=markersymbol;
run;
... View more
09-04-2024
08:50 AM
I've just created a ticket by the tech support.
... View more
09-04-2024
03:14 AM
Hi,
I was not anticipating any difference on the x-axis (when using valuesformat= or variable format) but there is one for the missing category.
Do you have any thought on this?
proc format;
value $sex 'M'='Male'
'F'='Female'
' '='Missing';
run;
data class;
set sashelp.class;
output;
if _n_=1 then
do;
sex=' ';
output;
end;
run;
proc sgplot data=class;
vbarbasic sex / response=height stat=mean missing;
format sex $sex.;
run;
proc sgplot data=class;
vbarbasic sex / response=height stat=mean missing;
xaxis valuesformat=$sex.;
run;
... View more
08-25-2024
05:12 AM
Thank you to both of you.
I was so focused on the picture in the online doc, that I didn't realise that I should double check the definition.
... View more
08-24-2024
06:16 AM
Based on the SAS Online documentation https://go.documentation.sas.com/doc/en/pgmsascdc/9.4_3.5/grstatproc/p07m2vpyq75fgan14m6g5pphnwlr.htm#n0s89yyivxyeren1ugj51fcu6a9p the two following procedure should output a different graph.
What is missing here?
proc sgplot data=sashelp.class;
hbarbasic sex;
xaxis values=(0 to 10)
ranges=(0-20)
labelpos=datacenter;
run;
proc sgplot data=sashelp.class;
hbarbasic sex;
xaxis values=(0 to 10)
ranges=(0-20)
labelpos=center;
run;
... View more