Description Usage Arguments Value Examples
Create a plot showing the improvement of groups relataive to the total population
1 | timeChangePlot(data1, data2, values, type, grain = 20)
|
data1 |
is a full dataframe with data on toxicity concentration and population counts. The dataframe must contain the variables: 'lconcentration' and the count of total population 'tot_pop' |
data2 |
is the same format of data, but at a second time period, over which you are interested in the changes |
values |
is a vector of strings refering to the columns you would like to see the relative changes in. All strings must match to a column in the dataframe. |
type |
should be either "rank" or "value". |
grain |
defines how fine grain you want the calulation to be. No input will default to 100 calculations |
Returns a plot object, showing the differences in changes in the groups, that can be saved or directly displayed. Returns a positive 'value' difference if group 1 improved more than group 2 over the interest period.Returns a negative 'rank' difference if group 1 improved more than group 2 in the defined time period.
1 | timeChangePlot(t1990, t2010, c("hispanic", "white", "black"), "value", 30)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.