You say that
The two data sets do not have common individuals or variables.
If you don't have (or don't want to use) the raw data, and only have summary data, some coding is required. More here:
https://www.lexjansen.com/nesug/nesug06/an/da24.pdf
Instead of merging the two data
(Perhaps you mean "instead of appending the two data")
This is a restriction which makes the programming much harder and ought to be eliminated. You (or your company or university) is paying for all the work already done by SAS to compare means and percents, plus SAS has tested it, fixed bugs and proved that these work in millions of real world applications — don't try to do this yourself.
Use the RAW data. Append the two data sets. This makes everything you do much simpler. Compare the means by PROC TTEST or PROC MEANS (or SURVEYMEANS). Compare the percents by using PROC FREQ (or SURVEYFREQ).
If there are only two group, compare MEAN of two group by PROC TTEST or PROC N1PARM + willconx.
compare PROPORTION(a.k.a risk ratio) of two group by
PROC FREQ ;
TABLE group*gender/relrisk ;
run;
@Rick_SAS wrote bolgs about these before.
ANOVA, or Analysis Of Variance, is used to compare the averages or means of two or more populations to better understand how they differ. Watch this tutorial for more.
Find more tutorials on the SAS Users YouTube channel.