This function takes as an argument a MODPATH pathline tibble (as generated using the readpathline function) and converts the contents into an sf vector file such as a shapefile. The pathline can be converted to real-world coordinates using coordinate offsets and rotations. The pathline can also be modified by applying a MAX_TIME limit that will only show pathlines that are less than or equal to the threshold time limit (MAX_TIME).
1 2 |
df |
This is the data frame containing the pathline information. If this dataframe is not present pth2sf will call readpathline using the supplied PATH. The default is NA. |
ofl |
is the output vector file name (including the filepath) of the SF file. |
PATH |
This is the full file path to the pathline file. When PATH is NA and df is not supplied this function will look in the current working directory for the pathline file. |
X_off |
This is the global X coordinate offset. |
Y_off |
This is the global Y coordinate offset. |
ROT |
This is the rotation angle in units of degrees. |
MAX_TIME |
is the maximum pathline travel time to be printed. This defaults to Inf. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.