Learn R Programming

rivervis (version 0.46.0)

RiverBlock: River Block-Chart

Description

This plots blocks to display qualitative data on the river chart.

Usage

RiverBlock(site, river, distance, value, riverlayout, arrangement, pt.shw = FALSE, hw.rat = 1.5, h.gap = 0.05, w.gap = 0.025, block.col = NA, block.lwd = 1, bd.col = "grey20", par.shw = TRUE, par.pos = 2, par.ofs = 1, par.cex = 0.6, par.adj = c(1, 0.5), par.txt = NA, lbl.shw = TRUE, lbl.cex = 0.7, lbl.adj = c(0.5, 2), lbl.ofs = 0.5, lbl.col = "black", lbl.srt = 0, lbl.pos = NULL)

Arguments

site
a vector of site names.
river
a vector of rivers on which the sites are located.
distance
a vector. The along-the-river distances between the sites and the mouth of the river.
value
a data frame containing the qualitative variables to be shown on the block-chart.
riverlayout
the output list of RiverLayout or RiverMap.
arrangement
a vector indicating the block number for each line.
pt.shw
show location point (TRUE) or not (FALSE).
hw.rat
the ratio of block height and width in the plotted diagram.
h.gap
vertical gap size between blocks. By default, the vertical gap is river height * 0.05 in each river chart.
w.gap
horizontal gap size between blocks when there is more than one block in each line. By default, the horizontal gap is largest block width * 0.025.
block.col
block colour.
block.lwd
block line width.
bd.col
block border col.
par.shw
show parameter names (TRUE) or not (FALSE).
par.pos
parameter label position. 1 for below, 2 for left, 3 for above, and 4 for right. See par for details.
par.ofs
parameter label position offset.
par.cex
parameter label size.
par.adj
parameter label adjustment. One or two values in [0,1] for x and y (optional) adjustment.
par.txt
parameter name.
lbl.shw
show labels (TRUE) or not (FALSE).
lbl.cex
label size.
lbl.adj
label adjustment. One or two values in [0,1] for x and y (optional) adjustment.
lbl.ofs
label position offset.
lbl.col
label colour.
lbl.srt
label angle.
lbl.pos
label position. 1 for below, 2 for left, 3 for above, and 4 for right. See par for details.

See Also

RiverLayout, RiverDraw, RiverMap, par.

Examples

Run this code
data(Ballinderry)

riverlayout <- RiverLayout(B.river$River,B.river$Length,
                           B.river$Parent,B.river$Position,
                           B.river$Distance, direction = -1)
RiverDraw(riverlayout)

RiverBlock(B.sitehm$Site, B.sitehm$River, B.sitehm$Distance,
           B.sitehm[4:9], riverlayout, c(1,1,2,2),
           block.col = fivecolours, lbl.adj = c(0.5,1.3))

RiverDraw(riverlayout)

RiverBlock(B.sitehm$Site, B.sitehm$River, B.sitehm$Distance,
           B.sitehm[4:9], riverlayout, c(1,1,2,2),
           block.col = fivecolours, lbl.adj = c(0.5,1.3),
           par.txt = c("ChanVeg", "ChanFlow", "BankVegLeft",
                       "Right", "RipLULeft", "Right"))

Run the code above in your browser using DataLab