| try_cast_as_numeric | R Documentation |
This function attempts to convert each column of a dataframe to numeric. Additionally, it replaces commas with dots to handle decimal separators.
If at any point of the conversion a Nan value is detected, where it was not present in the original column, then the original column is retained.
try_cast_as_numeric(dataframe)
dataframe |
( |
A dataframe with columns converted to numeric where possible.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.