read.LPJ: Prepare the output table from LPJ-GUESS for visualization

Description Usage Arguments Value Examples

Description

Stand ID and Patch ID start counting at 0 in the standard output. Here the value of 1 is added, to be consistent with R.

Usage

1
2
read.LPJ(file = "vegstruct.out", stand.id = 1, patch.id = NULL,
  year = NULL, lon = NULL, lat = NULL, grass = TRUE)

Arguments

file

the filename to be read

stand.id

the stand ID default to 0.

patch.id

if a single patch should be used (default all)

year

if a single year should be used (default all)

lon

if a single longitude should be used (default all). Should be defined, if more than one gridpoint is in the output.

lat

as above

grass

should grasses be included (so far they are not yet further processed).

Value

individual vegetation data.frame with equal indivuduals from each cohort.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
## Not run: 
dgvm3d.locations = read.table("gridlist.txt",
                              col.names=c("Lon", "Lat", "Name"), sep="\t",
                              stringsAsFactors=FALSE)
dgvm3d.succession=list()
for (i in 1:nrow(dgvm3d.locations)) {
  dgvm3d.succession[[dgvm3d.locations$Name[i]]] =
   read.LPJ("vegstruct.out",
            lon=dgvm3d.locations$Lon[i],
            lat=dgvm3d.locations$Lat[i])
   dgvm3d.succession[[i]] = dgvm3d.succession[[i]][!(dgvm3d.succession[[i]]$Year %% 5) &
                                                   dgvm3d.succession[[i]]$Year > 1859, ]
}

## End(Not run)

DGVM3D documentation built on May 2, 2019, 3:47 p.m.