Biology, images, analysis, design...
|"It has long been an axiom of mine that the little things are infinitely the most important" |
ProportionsOn this page: Example, with R, Definition and Use, Simple formula, Tips and Notes, References Download R R is Free, very powerful, and does the boring calculations & graphs for scientists.
Example, with R
A proportion is simply another name for a mean of a set of zeroes and ones.
Or you could find the proportion of ones with R
Definition and Use
A proportion is the relative frequency of items with a given characteristic in a given set (or p=f/n).
For example if 5 items are green, and 10 items are not green, then the proportion of green items is 5/(5+10), or 1/3.
In principle, a percentage (%) is simply a proportion times 100.
The crucial difference between a percentage an a proportion is you cannot have a proportion greater than one (1), but you can have a percentage greater than 100%. Proportions can only have values from zero to one. Percentages cannot be less than zero.
Note: Percentages calculated from a proportion (the ratio of two frequencies) have quite different properties from those calculated from the ratio of, for example, two prices.
Assuming y is a list of n items, coded as either 0 or 1:
the proportion of 1's in y is sum(y)/n
Or, if f of n items are classed as 'A':
Tips and Notes