Skip to main content
Bumped by Community user
Bumped by Community user
Bumped by Community user
added 30 characters in body
Source Link
KLee
  • 375
  • 2
  • 11

The goal of simulation is to produce a number of synthetic datasets, where the outcomes are a function of the known regression coefficients. I would like to know if my reasoning behind creating synthetic data is valid.

The steps involved are:
STEP 1: Based on the true (observed) data, fit GLM (e.g., gamma family).
STEP 2: Make a synthetic predictors.
STEP 3: Based on the output from STEP 2 and the fitted or predict function in R, obtain the expected outcome.
STEP 4: Based on the expected outcome, get the estimated shape and scale parameters (based on E(X) and Var(X)).
STEP 5: Obtain simulated outcome using the rgamma function in R.
STEP 6: Combine the output from STEP 5 and the synthetic predictors from STEP 2 to obtain the full simulated data.

In this manner, I am able to generate a synthetic dataset with the same dimension as the true (observed) dataset. However, I am wondering if this is a right way and if I can (or need to) remove STEP 4 - 6.

The goal of simulation is to produce a number of synthetic datasets, where the outcomes are a function of the known regression coefficients. I would like to know if my reasoning behind creating synthetic data is valid.

The steps involved are:
STEP 1: Based on the true (observed) data, fit GLM (e.g., gamma family).
STEP 2: Make a synthetic predictors.
STEP 3: Based on the output from STEP 2 and the fitted or predict function in R, obtain the expected outcome.
STEP 4: Based on the expected outcome, get the estimated shape and scale parameters (based on E(X) and Var(X)).
STEP 5: Obtain simulated outcome using the rgamma function in R.
STEP 6: Combine the output from STEP 5 and STEP 2 to obtain the full simulated data.

In this manner, I am able to generate a synthetic dataset with the same dimension as the true (observed) dataset. However, I am wondering if this is a right way and if I can (or need to) remove STEP 4 - 6.

The goal of simulation is to produce a number of synthetic datasets, where the outcomes are a function of the known regression coefficients. I would like to know if my reasoning behind creating synthetic data is valid.

The steps involved are:
STEP 1: Based on the true (observed) data, fit GLM (e.g., gamma family).
STEP 2: Make a synthetic predictors.
STEP 3: Based on the output from STEP 2 and the fitted or predict function in R, obtain the expected outcome.
STEP 4: Based on the expected outcome, get the estimated shape and scale parameters (based on E(X) and Var(X)).
STEP 5: Obtain simulated outcome using the rgamma function in R.
STEP 6: Combine the output from STEP 5 and the synthetic predictors from STEP 2 to obtain the full simulated data.

In this manner, I am able to generate a synthetic dataset with the same dimension as the true (observed) dataset. However, I am wondering if this is a right way and if I can (or need to) remove STEP 4 - 6.

Source Link
KLee
  • 375
  • 2
  • 11

Simulated data (with the outcome and predictors) from a GLM model

The goal of simulation is to produce a number of synthetic datasets, where the outcomes are a function of the known regression coefficients. I would like to know if my reasoning behind creating synthetic data is valid.

The steps involved are:
STEP 1: Based on the true (observed) data, fit GLM (e.g., gamma family).
STEP 2: Make a synthetic predictors.
STEP 3: Based on the output from STEP 2 and the fitted or predict function in R, obtain the expected outcome.
STEP 4: Based on the expected outcome, get the estimated shape and scale parameters (based on E(X) and Var(X)).
STEP 5: Obtain simulated outcome using the rgamma function in R.
STEP 6: Combine the output from STEP 5 and STEP 2 to obtain the full simulated data.

In this manner, I am able to generate a synthetic dataset with the same dimension as the true (observed) dataset. However, I am wondering if this is a right way and if I can (or need to) remove STEP 4 - 6.