forked from dankelley/oce
-
Notifications
You must be signed in to change notification settings - Fork 0
/
as.windrose.Rd
62 lines (57 loc) · 2.02 KB
/
as.windrose.Rd
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
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/windrose.R
\name{as.windrose}
\alias{as.windrose}
\title{Create a Windrose Object}
\usage{
as.windrose(x, y, dtheta = 15, debug = getOption("oceDebug"))
}
\arguments{
\item{x}{The x component of wind speed (or stress) \emph{or} an object of class
\code{met} (see \code{\link{met-class}}), in which case the \code{u} and
\code{v} components of that object are used for the components of wind speed,
and \code{y} here is ignored.}
\item{y}{The y component of wind speed (or stress).}
\item{dtheta}{The angle increment (in degrees) within which to classify the data.}
\item{debug}{A flag that turns on debugging. Set to 1 to get a moderate amount
of debugging information, or to 2 to get more.}
}
\value{
An object of \code{\link{windrose-class}} that contains the standard
\code{oce} slots named \code{data}, \code{metadata} and \code{proxessingLog}.
The \code{data} slot contains
\describe{
\item{\code{n}}{the number of x values}
\item{\code{x.mean}}{the mean of the x values}
\item{\code{y.mean}}{the mean of the y values}
\item{\code{theta}}{the central angle (in degrees) for the class}
\item{\code{count}}{the number of observations in this class}
\item{\code{mean}}{the mean of the observations in this class}
\item{\code{fivenum}}{the \code{\link{fivenum}} vector for
observations in this class (the min, the lower hinge, the
median, the upper hinge, and the max)}
}
}
\description{
Create a wind-rose object, typically for plotting with
\code{\link{plot,windrose-method}}.
}
\examples{
library(oce)
xcomp <- rnorm(360) + 1
ycomp <- rnorm(360)
wr <- as.windrose(xcomp, ycomp)
summary(wr)
plot(wr)
}
\seealso{
Other things related to windrose data: \code{\link{[[,windrose-method}},
\code{\link{[[<-,windrose-method}},
\code{\link{plot,windrose-method}},
\code{\link{summary,windrose-method}},
\code{\link{windrose-class}}
}
\author{
Dan Kelley, with considerable help from Alex Deckmyn.
}
\concept{things related to windrose data}