Skip to main content
deleted 159 characters in body
Source Link
John
  • 23.6k
  • 9
  • 59
  • 93

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ xx_as_7_categories) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels are likely not continuous (from your description) bur rather categorical. It appears that there is no 5.4 possible.

I realize that what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realize that what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x_as_7_categories)
anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that the 7 levels are likely not continuous (from your description) bur rather categorical. It appears that there is no 5.4 possible.

I realize that what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

added 4 characters in body
Source Link
John
  • 23.6k
  • 9
  • 59
  • 93

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realizedrealize that what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realized what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realize that what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

added 232 characters in body
Source Link
John
  • 23.6k
  • 9
  • 59
  • 93

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realized what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

There are a number of things you could do. You could do plain old likelihood ratio tests or compare AIC's (a penalized likelihood ratio test). You can use these to compare models. The AIC's have the advantage of penalizing the 2 level variable for complexity over the continuous variable.

m1 <- lm(y ~ x_as_2_categories)
m2 <- lm(y ~ x) # a numeric continuous x

anova(m1, m2)

You might want to look at some basic papers on this sort of testing.

A critical thing to note is that if you don't expect a continuous effect of the 7 level version of the x variable but you are considering it as 7 categories that's yet a third model and you'll need to be careful about whether and how much you penalize the model for the extra parameters of having 7 levels.

I realized what I've described are simple models and you say you have survey data but that description is incredibly vague and difficult to make more precise recommendations on. The general idea is still applicable, generate multiple models and see which fits better. You'll want to read on statistical model comparison.

added 232 characters in body
Source Link
John
  • 23.6k
  • 9
  • 59
  • 93
Loading
Source Link
John
  • 23.6k
  • 9
  • 59
  • 93
Loading