Description Usage Arguments Examples
Correct numerical Ids In our analysis the Id column refers to the sequenced id. In many cases this was a number; but later it matched the SPECID + and extention. Therefore the column should be read as string. However, Pandas for some reason converted the numbers to decimal format. This function corrects that and returns a string number with out the ".0"
1 | correct_id(df, col)
|
df |
data frame or tibble to correct |
col |
column that needs to be corrected. |
1 2 | cov_sample<-dplyr::tibble(Id=c("129.0","MH00000"))
correct_id(cov_sample,Id)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.