Description Usage Arguments Examples
Using the oversampling of "boys", the returned object from "sample_data()"; imputes a made-up linear relationship between fabricated SES variable (think household income) and the final height in column 32 of data_in. In future I will build in params for the 100 and the 12 and the rnorm in teh SES assignment.
1 | calculate_ses(data_in = NULL, slope = 100, intercept = 12)
|
data_in |
an object returned from sample_data() |
slope |
a number that determines the linear relationship of final height and SES. For instance, if slope=100 and intercept=12, then the SES for individual i is SES(i) = 100*( height(i) - minimum of all heights )/(max of all heights - min of all heights) + 12 + rnorm(1) |
intercept |
a number, see explanation of slope |
1 2 3 4 | d<-prep_data()
head(d)
over_samp_mat<-sample_data(d,1000)
with_ses <- calculate_ses(over_samp_mat)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.