Hi,

I am using a user written command cdfplot in Stata 15 to generate normalized cdf by a categorical variable using the code
Code:
cdfplot x [pweight=weight], normal nocdf by(y)
However, I am getting invalid syntax error. The code works with some categorical variables but results to an error while using other variables.

Kind request for some help on the issue.

Thanks in advance.

Best,
Stephen.