My gut feeling is that you should be able to filter on formats within SGPLOT, because you can plot formats in SGPLOT. Can you please confirm if you have exposure data and all_LR data for that where clause?
It would also be helpful to have access to the egidwh_oneway4 dataset.
In any event, I'm sure that you worked out that you can perform the where clause with a datastep, and then use SGPLOT on the transformed dataset.
In which library does your format NOLEVELS exist? If it resides in a permanent library then likely the library is not in the current FMTSEARCH path. Or if the format is being created in the work library then it does not persist from SAS session to session and the code needs to be rerun.
Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.
If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website.