Description Usage Arguments Details Examples
Calculate the percent value of a vector (stunning this isn't built-in to R)
1 |
x |
Value or vector of number to calculate as percentage of y |
y |
The total to calculate percent x from, by default the sum of the value(s) of x |
places |
Number of places after the decimal to round the result to (default value is 1) |
This function calculates percentages, generally on values in data frame field. If you'd like the values to be normalized simply divide the result by 100. To use this function to calculate percent change simply code the current or future value as x and prior value to y as x-prior.
1 2 3 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.