I'm trying to run bivar logistic regression on 2 variables but from 2 datasets that have the same var names just from different timepoints. I've listed the code I have so far but essentially, var 2 needs to be from the first dataset and var 1 and 3 need to be from a combination of both datasets. I've tried renaming the variable that needs data from only one data set but when I add the other set, there are fewer values for some reason. data work.asdf; set 'dataset1'(rename=(var2=var2a)); set 'dataset2'; ... This is what I was trying to run: proc sort; by var1; proc freq; by var1; table var2a*var3 / expected cellchi2 chisq; run;
... View more