as_multi_xy: Create a multiXY object

Description Usage Arguments Value Examples

View source: R/as_multi_xy.R

Description

as_multi_xy takes a list or data frame of XRPD data and ensures that the data meet various requirements to create a multiXY object. Once a multiXY object has been created, it can easily be plotted using the associated plot.multiXY method.

Usage

1

Arguments

x

a list or data frame of XRPD data

...

other arguments

Value

a multiXY object.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
#EXAMPLE 1

#load soils data
data(soils)

#extract first two samples from the list
soils <- soils[c(1:2)]

#convert to multiXY
soils <- as_multi_xy(soils)

#EXAMPLE 2
#load the soils data
data(soils)

#Convert to data frame
soils_df <- multi_xy_to_df(soils,
                           tth = TRUE)

#Convert back to multiXY object
soils2 <- as_multi_xy(soils_df)

powdR documentation built on Aug. 13, 2021, 5:08 p.m.