Description Usage Arguments Author(s) Examples
This functions plots a random number (within user-defined limits) of symbols or
.png images at random positions in the plotting window, asks you to type in your
estimate, and then shows you exactly how many symbols/pictures there were and the
extent of your estimate error. It also stores these data in a VisCountSessions
table which you can retrieve later and which can be used by the visCountStats
function to provide performance statistics.
1 |
Nmax |
maximum number of symbols to plot; defaults to 100. |
Nmin |
minimum number of symbols to plot; defaults to 10. |
shape |
plotting items to use. Can be one of the plotting symbols available in
R (see 'pch' values in |
size |
size for the plotting symbols (see 'cex' in |
col |
colour for the plotting symbols (see 'col' in |
bg |
colour for the plot background. Can be one of the colours available in R (see 'bg' in |
A. Marcia Barbosa
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | ## Not run:
# practise visCount and enter your estimates as prompted:
visCount() # repeat until bored
# practise also with different shapes, sizes, colours and backgrounds:
visCount(shape = "^", bg = "white")
visCount(shape = "~", size = 1.3)
visCount(shape = "x", size = 2, col = "brown")
visCount(shape = "Y", bg = "wheat")
# practise with different number limits
# (you can combine with any of the arguments above):
visCount(Nmax = 500, Nmin = 100)
# you can also use animal and/or background pictures in PNG format
# (you need to have the png R package installed for this);
# here are some examples with downloaded public domain images:
download.file(url = "http://viscount.r-forge.r-project.org/img/flamingo_flying.png",
destfile = "flamingo_flying.png")
download.file(url = "http://viscount.r-forge.r-project.org/img/clouds.png",
destfile = "clouds.png")
visCount(shape = "flamingo_flying.png", bg = "lightblue")
visCount(shape = "flamingo_flying.png", size = 0.5, bg = "clouds.png")
download.file(url = "http://viscount.r-forge.r-project.org/img/gull_standing.png",
destfile = "gull_standing.png")
download.file(url = "http://viscount.r-forge.r-project.org/img/water.png",
destfile = "water.png")
visCount(shape = "gull_standing.png", bg = "grey")
visCount(shape = "gull_standing.png", bg = "water.png")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.