I want to run a t-test that the population mean is equal to a specified value given by a scalar. For example, the sample of the population is given by the variable "mpg" and the scalar has the name "alpha" and is equal to 23.
However, using the syntax
yields "variable alpha not found".
Using the syntax
yields "invalid syntax"
While using the syntax
works.
How can I make "ttest" read the numerical value of the scalar "alpha"?
However, using the syntax
Code:
ttest mpg == alpha
Using the syntax
Code:
ttest mpg == `alpha'
While using the syntax
Code:
ttest mpg == 23
How can I make "ttest" read the numerical value of the scalar "alpha"?
Comment