| as_xy {powdR} | R Documentation | 
Create an XY object
Description
as_xy takes a data frame of XY XRPD data and ensures that it
meets the criteria for an XY object. These requirements
include that the data contains 2 columns of numeric data in a dataframe.
Once an XY object has been created, it can easily be plotted using the
associated plot.XY method.
Usage
as_xy(x)
Arguments
| x | a data frame (column 1 = 2theta, column 2 = counts) | 
Value
an XY object.
Examples
# Load soils xrd data
data(rockjock_mixtures)
xy <- as_xy(rockjock_mixtures$Mix1)
class(xy)
## Not run: 
plot(xy, wavelength = "Cu")
plot(xy, wavelength = "Cu", interactive = TRUE)
## End(Not run)
[Package powdR version 1.3.0 Index]