If you can post some sample that, that will help us try out various solutions.
To be coded like the example you referenced (https://blogs.sas.com/content/graphicallyspeaking/files/2014/06/Swimmer_93.txt), you'll need to add nocycleattrs to the proc sgplot line
proc sgplot data = all_therapy dattrmap=attrmap nocycleattrs;
Also, make sure that all the values in your 'attrmap' dataset are reading in correctly. I assume the way your code is written that your code & datalines is in the correct columns it's looking for(?), but that when you copy-n-pasted it into the comment above it collapsed the spaces(?) Here's a slightly different version of the code that doesn't depend on the datalines being column-delimited, if you need it:
data attrmap; length id $10 value $20 linecolor fillcolor $20; infile datalines dlm=','; input ID value linecolor fillcolor; datalines; trtcat1,Any immuno,blue,blue trtcat1,Any other,charcoal,charcoal trtcat1,Chemo,orange,orange trtcat1,SRS,green,green trtcat1,Targeted,purple,purple trtcat1,WBRT,black,black trtcat1,cranio,gold,gold trtcat1,radio,pink,pink trtcat2,Any immuno,blue,blue trtcat2,Any other,charcoal,charcoal trtcat2,Chemo,orange,orange trtcat2,SRS,green,green trtcat2,Targeted,purple,purple trtcat2,WBRT,black,black trtcat2,cranio,gold,gold trtcat2,radio,pink,pink trtcat3,Any immuno,blue,blue trtcat3,Any other,charcoal,charcoal trtcat3,Chemo,orange,orange trtcat3,SRS,green,green trtcat3,Targeted,purple,purple trtcat3,WBRT,black,black trtcat3,cranio,gold,gold trtcat3,radio,pink,pink trtcat4,Any immuno,blue,blue trtcat4,Any other,charcoal,charcoal trtcat4,Chemo,orange,orange trtcat4,SRS,green,green trtcat4,Targeted,purple,purple trtcat4,WBRT,black,black trtcat4,cranio,gold,gold trtcat4,radio,pink,pink ; run;
... View more