generated from r-hyperspec/pkg-skeleton
/
hySpc-read-ENVI.Rmd
90 lines (77 loc) · 2.85 KB
/
hySpc-read-ENVI.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
---
# For vignette ---------------------------------------------------------------
title: 'Import and Export Files with ENVI files'
subtitle: 'Tutorial on Spectra File Import from ENVI Files for "hyperSpec"'
description: 'Tutorial on spectra file import from ENVI files for "hyperSpec".'
# Authors --------------------------------------------------------------------
author:
- name: Sang Truong
email: sttruong@stanford.edu
corresponding : yes
affiliation : Stanford University
# Document -------------------------------------------------------------------
date: "`r Sys.Date()`"
output:
bookdown::html_document2:
base_format: rmarkdown::html_vignette
toc: yes
toc_depth: 2
fig_caption: yes
number_sections: true
css:
- vignette.css
- style.css
vignette: >
% \VignetteIndexEntry{Introduction to Package "hySpc.read.ENVI"}
% \VignetteKeyword{hySpc.read.ENVI}
% \VignettePackage{hySpc.read.ENVI}
% \VignetteEngine{knitr::rmarkdown}
% \VignetteEncoding{UTF-8}
# Citations/References -------------------------------------------------------
link-citations: yes
bibliography: resources/intro-pkg.bib
biblio-style: plain
csl: elsevier-with-titles.csl
# Pkgdown --------------------------------------------------------------------
pkgdown:
as_is: true
set_null_theme: no
---
```{r cleanup-hyperspec, include = FALSE}
# Clean up to ensure reproducible workspace ----------------------------------
rm(list = ls(all.names = TRUE))
```
```{r setup, include = FALSE}
# Packages -------------------------------------------------------------------
library(hySpc.read.ENVI)
# Functions ------------------------------------------------------------------
source("vignette-functions.R", encoding = "UTF-8")
# Settings -------------------------------------------------------------------
source("vignette-default-settings.R", encoding = "UTF-8")
# Temporary options ----------------------------------------------------------
# Change the value of this option in "vignette-default-settings.R"
show_reviewers_notes <- getOption("show_reviewers_notes", TRUE)
```
```{r bib, echo = FALSE, paged.print = FALSE}
dir.create("resources", showWarnings = FALSE)
knitr::write_bib(
c("hyperSpec"),
file = "resources/intro-pkg.bib"
)
```
<!-- This chunk inserts common info about all the vignettes -->
```{r, echo = FALSE, results = "asis"}
res <- knitr::knit_child("list-of-vignettes.md", quiet = TRUE)
cat(res, sep = "\n")
```
<!-- This chunk demonstrates example of read_ENVI_HySpex() and read_ENVI()-->
```{r eval=FALSE}
filename <- system.file("extdata", "HySpexNIR.hyspex", package = "hySpc.read.ENVI")
hyspex <- hySpc.read.ENVI::read_ENVI_HySpex(filename)
hyspex
```
```{r eval=FALSE}
filename <- system.file("extdata", "toy.bil", package = "hySpc.read.ENVI")
toy <- hySpc.read.ENVI::read_ENVI(filename)
toy
```