Description Usage Arguments Value Examples
Function to introduce additional NAs for prediction error calculation.
1 | NA_Generator(SNP_df, percent)
|
SNP_df |
Original data of SNP. It may contain some SNP |
percent |
The final percentage of total NA's we want in the dataset. |
a list of variables: 1. SNP_NA_df: the dataset with additional SNPs. 2. NA_percent_orig: original missing percentable in the dataset. 3. NA_percent_generate: introduced NA percentage. 4. NP_generate_positions: the positions of the introduced NA's.
1 2 3 4 5 6 7 8 | data("SNP_orig_sub")
## original NA ratio is 0.018
SNP_NA_df02 <- NA_Generator(SNP_orig_sub, 0.2)
## Introduced another 18% of NAs.
SNP_NA_df <- NA_Generator(SNP_orig_sub, 0.01)
## Should report an error: alread has 1.8% NA's, higher than the
## target percentage.
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.