draw_simple_OCN: Draw an Optimal Channel Network

Description Usage Arguments Value Examples

View source: R/draw_simple_OCN.R

Description

Function that plots the non-aggregated OCN as calculated by create_OCN.

Usage

1
2
draw_simple_OCN(OCN, thrADraw = 0.002 * OCN$dimX * OCN$dimY *
  OCN$cellsize^2, riverColor = "#0066FF", easyDraw = NULL)

Arguments

OCN

List as produced by create_OCN.

thrADraw

Threshold drainage area value used to display the network.

riverColor

Color used to plot the river.

easyDraw

Logical. If TRUE, the whole network is displayed, and pixels with drainage area lower than thrADraw are displayed in light gray. If FALSE, only pixels with drainage area greater or equal to thrADraw are displayed. Default is FALSE if OCN$nNodes <= 40000, and TRUE otherwise. Note that setting easyDraw = FALSE for large networks might slow down the process considerably.

Value

No output is returned.

Examples

1
2
3
4
5
6
7
8
# 1a) draw OCN with default settings
draw_simple_OCN(OCN_250_T)
# 1b) same as above, but with decreased thrADraw
draw_simple_OCN(OCN_250_T, thrADraw = 0.001 * OCN_250_T$dimX * OCN_250_T$dimY)

# 1c) same as the first example, but include the portion of network  
# with drainage area lower than thrADraw 
draw_simple_OCN(OCN_250_T, easyDraw = FALSE) # this will take some seconds

OCNet documentation built on May 17, 2021, 5:07 p.m.