read.data {IsoplotR} | R Documentation |
Read geochronological data
Description
Cast a .csv
file or a matrix into one of IsoplotR
's
data classes
Usage
read.data(x, ...)
## Default S3 method:
read.data(
x,
method = "U-Pb",
format = 1,
ierr = 1,
d = diseq(),
Th02i = c(0, 0),
Th02U48 = c(0, 0, 1e+06, 0, 0, 0, 0, 0, 0),
U8Th2 = 0,
...
)
## S3 method for class 'data.frame'
read.data(
x,
method = "U-Pb",
format = 1,
ierr = 1,
d = diseq(),
Th02i = c(0, 0),
Th02U48 = c(0, 0, 1e+06, 0, 0, 0, 0, 0, 0),
U8Th2 = 0,
...
)
## S3 method for class 'matrix'
read.data(
x,
method = "U-Pb",
format = 1,
ierr = 1,
d = diseq(),
Th02i = c(0, 0),
Th02U48 = c(0, 0, 1e+06, 0, 0, 0, 0, 0, 0),
U8Th2 = 0,
...
)
Arguments
x |
either a file name ( |
... |
optional arguments to the |
method |
one of |
format |
formatting option, depends on the value of
if
where optional columns are marked in round brackets if
if
if
if
if
where if
where if
where if
where if
where all values are activity ratios if
if
|
ierr |
indicates whether the analytical uncertainties of the input are provided as:
|
d |
an object of class |
Th02i |
2-element vector with the assumed initial
|
Th02U48 |
9-element vector with the measured composition of
the detritus, containing |
U8Th2 |
|
Details
IsoplotR provides the following example input files:
U-Pb:
UPb1.csv
,UPb2.csv
,UPb3.csv
,UPb4.csv
,UPb5.csv
,UPb6.csv
,UPb7.csv
,UPb8.csv
Pb-Pb:
PbPb1.csv
,PbPb2.csv
,PbPb3.csv
Th-Pb:
ThPb1.csv
,ThPb2.csv
,ThPb3.csv
Ar-Ar:
ArAr1.csv
,ArAr2.csv
,ArAr3.csv
K-Ca:
KCa1.csv
,KCa2.csv
,KCa3.csv
Re-Os:
ReOs1.csv
,ReOs2.csv
,ReOs3.csv
Sm-Nd:
SmNd1.csv
,SmNd2.csv
,SmNd3.csv
Rb-Sr:
RbSr1.csv
,RbSr2.csv
,RbSr3.csv
Lu-Hf:
LuHf1.csv
,LuHf2.csv
,LuHf3.csv
Th-U:
ThU1.csv
,ThU2.csv
,ThU3.csv
ThU4.csv
fissiontracks:
FT1.csv
,FT2.csv
,FT3.csv
U-Th-He:
UThHe.csv
,UThSmHe.csv
detritals:
DZ.csv
other:
LudwigMixture.csv
,LudwigMean.csv
,LudwigKDE.csv
,LudwigSpectrum.csv
The contents of these files can be viewed using the
system.file(...)
function. For example, to read the
ArAr1.csv
file:
fname <- system.file('ArAr1.csv',package='IsoplotR')
ArAr <- read.data(fname,method='Ar-Ar',format=1)
Value
An object of class UPb
, PbPb
, ThPb
,
KCa
, RbSr
, SmNd
, LuHf
, ReOs
,
UThHe
, fissiontracks
, detritals
or
PD
. See classes
for further details.
See Also
Examples
f1 <- system.file("UPb1.csv",package="IsoplotR")
file.show(f1) # inspect the contents of 'UPb1.csv'
d1 <- read.data(f1,method="U-Pb",format=1)
concordia(d1)
f2 <- system.file("ArAr1.csv",package="IsoplotR")
d2 <- read.data(f2,method="Ar-Ar",format=1)
agespectrum(d2)
f3 <- system.file("ReOs1.csv",package="IsoplotR")
d3 <- read.data(f3,method="Re-Os",format=1)
isochron(d2)
f4 <- system.file("FT1.csv",package="IsoplotR")
d4 <- read.data(f4,method="fissiontracks",format=1)
radialplot(d4)
f5 <- system.file("UThSmHe.csv",package="IsoplotR")
d5 <- read.data(f5,method="U-Th-He")
helioplot(d5)
f6 <- system.file("ThU2.csv",package="IsoplotR")
d6 <- read.data(f6,method="Th-U",format=2)
evolution(d6)
# one detrital zircon U-Pb file (detritals.csv)
f7 <- system.file("DZ.csv",package="IsoplotR")
d7 <- read.data(f7,method="detritals")
kde(d7)
# four 'other' files (LudwigMixture.csv, LudwigSpectrum.csv,
# LudwigMean.csv, LudwigKDE.csv)
f8 <- system.file("LudwigMixture.csv",package="IsoplotR")
d8 <- read.data(f8,method="other",format=2)
radialplot(d8)