Description Usage Arguments Value Examples
Runs the Williamson-York bivariate weighted least square regression algorith.
1 |
x |
vector of x values |
xsd |
standard deviation of x values |
y |
vector of y values |
ysd |
standard deviation of y values |
print |
boolean to print results when storing results object |
plot |
boolean to produce plot with uncertainty ellipses OLS and WY regression lines |
tol |
tolerance for algorithm (defaults to 1e-8) |
list of WY.Summary, OLS regression, WY intercept, Intercept SE, WY slope, Slope SE, r anologue, R2 anologue, p-value, and plot
1 2 3 4 5 6 7 | X <- c(7.042, 2.419, 3.371, 2.394, 3.633, 3.904, 2.915, 7.676, 3.338, 2.440, 3.073, 2.651, 4.593, 4.734, 6.614, 5.403, 6.529, 6.576, 8.415, 3.306)
Xsd<-c(1.660, 1.296, 1.283, 0.403, 1.686, 0.793, 1.019, 0.376, 1.792, 1.215, 1.030, 0.706, 1.314, 0.246, 0.590, 1.697, 0.425, 0.708, 0.417, 0.957)
Y <- c(5.393, 3.793, 5.055, 2.769, 9.481, 3.704, 0.408, 6.143, 3.754, 6.163, 1.012, 4.447, 4.465, 4.769, 5.623, 5.255, 9.506, 3.071, 5.640, 2.837)
Ysd<-c(0.618, 1.523, 1.045, 0.208, 1.812, 1.774, 1.508, 1.599, 0.641, 0.723, 0.230, 0.774, 1.585, 0.369, 0.372, 1.087, 0.518, 1.122, 0.786, 1.184)
XYData<-data.frame(X=X,Xsd=Xsd,Y=Y,Ysd=Ysd)
WYtest <- WYbwls(x=XYData$X, xsd=XYData$Xsd, y=XYData$Y, ysd=XYData$Ysd, print=T, plot=T)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.