I have got the model but it produces very impossible results. R Square equals to 1. and F equals to infinitive:((
Here is an example .
http://blogs.sas.com/content/iml/2016/03/02/dummy-variables-sasiml.html
Especial this part:
Y = Cholesterol; /* response variable */
Intercept = j(nrow(Y), 1, 1);
X1 = designf( Sex );
X2 = designf( BP_Status );
X = Intercept || X1 || X2; /* design matrix with EFFECT parameterization */
/* Matrix formulation of one-way ANOVA (cell means model): Y = X*beta + epsilon
See https://en.wikipedia.org/wiki/Design_matrix */
b = solve( X`*X, X`*Y ); /* solve normal equations */
print b[rowname={"Intercept" "Sex:Female" "BP_Status:High" "BP_Status:Normal"}];
Many thanks for your response. I looked at the example that you provided. Hopefuly it would work.
Since no one else has mentioned it....
With 55 variables and only 40 observations, you have an overspecified system. There are enough parameters to fit the data exactly, which is why you are seeing R-square=1. However, the model is meaningless.
An analagous example is asking for the "line of best fit" through one data point.
Many thanks. so you mean like finding a hyperline, right?
Well, technically it is a hypersurface, not a line. Like trying to fit a plane to a data set that has only one or two points.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
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.