Week6

Author

Jonas Amacher

Tasks 1: Import and visualize spatial data

What information does the dataset contain?

Simple feature collection with 6 features and 2 fields
Geometry type: POLYGON
Dimension:     XY
Bounding box:  xmin: 2570249 ymin: 1202176 xmax: 2571719 ymax: 1203436
Projected CRS: CH1903+ / LV95
# A tibble: 6 × 3
  FieldID Frucht                                                            geom
    <dbl> <chr>                                                    <POLYGON [m]>
1       1 Roggen ((2570914 1202743, 2570917 1202749, 2570985 1202833, 2571294 1…
2       0 <NA>   ((2570893 1202758, 2570893 1202758, 2570959 1202845, 2570985 1…
3       0 <NA>   ((2570868 1202776, 2570872 1202781, 2570913 1202828, 2570946 1…
4       2 Wiese  ((2570882 1203234, 2570641 1202974, 2570630 1202983, 2570606 1…
5       3 Weide  ((2570249 1203116, 2570371 1203328, 2570481 1203197, 2570390 1…
6       5 Weide  ((2570378 1203320, 2570466 1203436, 2570552 1203289, 2570481 1…

What is the geometry type of the dataset (possible types are: Point, Lines and Polygons)?

[1] POLYGON
18 Levels: GEOMETRY POINT LINESTRING POLYGON MULTIPOINT ... TRIANGLE

What are the data types of the other columns?

sf [975 × 3] (S3: sf/tbl_df/tbl/data.frame)
 $ FieldID: num [1:975] 1 0 0 2 3 5 6 4 7 0 ...
 $ Frucht : chr [1:975] "Roggen" NA NA "Wiese" ...
 $ geom   :sfc_POLYGON of length 975; first list element: List of 1
  ..$ : num [1:12, 1:2] 2570914 2570917 2570985 2571294 2571719 ...
  ..- attr(*, "class")= chr [1:3] "XY" "POLYGON" "sfg"
 - attr(*, "sf_column")= chr "geom"
 - attr(*, "agr")= Factor w/ 3 levels "constant","aggregate",..: NA NA
  ..- attr(*, "names")= chr [1:2] "FieldID" "Frucht"

What is the coordinate system of the dataset?

Coordinate Reference System:
  User input: CH1903+ / LV95 
  wkt:
PROJCRS["CH1903+ / LV95",
    BASEGEOGCRS["CH1903+",
        DATUM["CH1903+",
            ELLIPSOID["Bessel 1841",6377397.155,299.1528128,
                LENGTHUNIT["metre",1]]],
        PRIMEM["Greenwich",0,
            ANGLEUNIT["degree",0.0174532925199433]],
        ID["EPSG",4150]],
    CONVERSION["Swiss Oblique Mercator 1995",
        METHOD["Hotine Oblique Mercator (variant B)",
            ID["EPSG",9815]],
        PARAMETER["Latitude of projection centre",46.9524055555556,
            ANGLEUNIT["degree",0.0174532925199433],
            ID["EPSG",8811]],
        PARAMETER["Longitude of projection centre",7.43958333333333,
            ANGLEUNIT["degree",0.0174532925199433],
            ID["EPSG",8812]],
        PARAMETER["Azimuth at projection centre",90,
            ANGLEUNIT["degree",0.0174532925199433],
            ID["EPSG",8813]],
        PARAMETER["Angle from Rectified to Skew Grid",90,
            ANGLEUNIT["degree",0.0174532925199433],
            ID["EPSG",8814]],
        PARAMETER["Scale factor at projection centre",1,
            SCALEUNIT["unity",1],
            ID["EPSG",8815]],
        PARAMETER["Easting at projection centre",2600000,
            LENGTHUNIT["metre",1],
            ID["EPSG",8816]],
        PARAMETER["Northing at projection centre",1200000,
            LENGTHUNIT["metre",1],
            ID["EPSG",8817]]],
    CS[Cartesian,2],
        AXIS["(E)",east,
            ORDER[1],
            LENGTHUNIT["metre",1]],
        AXIS["(N)",north,
            ORDER[2],
            LENGTHUNIT["metre",1]],
    USAGE[
        SCOPE["Cadastre, engineering survey, topographic mapping (large and medium scale)."],
        AREA["Liechtenstein; Switzerland."],
        BBOX[45.81,5.95,47.81,10.5]],
    ID["EPSG",2056]]

Task 2: Annotate Trajectories from vector data

Wild boar locations (May–June) over Fanel crop fields

Explore the annotated dataset:

Simple feature collection with 6 features and 2 fields
Geometry type: POLYGON
Dimension:     XY
Bounding box:  xmin: 2570249 ymin: 1202176 xmax: 2571719 ymax: 1203436
Projected CRS: CH1903+ / LV95
# A tibble: 6 × 3
  FieldID Frucht                                                            geom
    <dbl> <chr>                                                    <POLYGON [m]>
1       1 Roggen ((2570914 1202743, 2570917 1202749, 2570985 1202833, 2571294 1…
2       0 <NA>   ((2570893 1202758, 2570893 1202758, 2570959 1202845, 2570985 1…
3       0 <NA>   ((2570868 1202776, 2570872 1202781, 2570913 1202828, 2570946 1…
4       2 Wiese  ((2570882 1203234, 2570641 1202974, 2570630 1202983, 2570606 1…
5       3 Weide  ((2570249 1203116, 2570371 1203328, 2570481 1203197, 2570390 1…
6       5 Weide  ((2570378 1203320, 2570466 1203436, 2570552 1203289, 2570481 1…

Task 3: Explore annotated trajectories

Task 4: Import and visualize vegetationindex (raster data)

Vegetation Height Model plotted with Base R

Vegetation Height Model plotted with Tmap

Task 5: Annotate Trajectories from raster data

Simple feature collection with 6 features and 7 fields
Geometry type: POINT
Dimension:     XY
Bounding box:  xmin: 2570059 ymin: 1205242 xmax: 2570096 ymax: 1205256
Projected CRS: CH1903+ / LV95
# A tibble: 6 × 8
  TierID TierName CollarID DatetimeUTC                E        N
  <chr>  <chr>       <dbl> <dttm>                 <dbl>    <dbl>
1 002A   Sabi        12275 2015-05-01 00:00:17 2570093. 1205256.
2 002A   Sabi        12275 2015-05-01 00:15:25 2570093. 1205249.
3 002A   Sabi        12275 2015-05-01 00:30:15 2570091. 1205253.
4 002A   Sabi        12275 2015-05-01 00:45:15 2570059. 1205242.
5 002A   Sabi        12275 2015-05-01 01:00:30 2570078. 1205246.
6 002A   Sabi        12275 2015-05-01 01:15:43 2570096. 1205256.
# ℹ 2 more variables: geometry <POINT [m]>, veg_height <dbl>

Habitat of wild boars by vegetation height