sampleLSV: Create Subsample of a Simulated Linear Sweep Voltammogram

Description Usage Arguments Value Examples

Description

Used to create a reduced data file of potentials and currents for a linear sweep voltammogram. When passed to plotLSV, the resulting plot shows the data as discrete points instead of as a line.

Usage

1
sampleLSV(filename, data.reduction = 1)

Arguments

filename

The filename that contains the result of a simulated linear sweep voltammetry experiment (created using the lsvSim function).

data.reduction

A value that gives the percentage of the original data to keep, which then is spaced evenly across the full data set.

Value

Returns a list with the following components

expt

type of experiment; LSV for a linear sweep voltammetry experiment

file_type

value that indicates whether the output includes all data (full) or a subset of data (reduced); defaults to reduced

current

vector giving the current as a function of time

potential

vector giving the potential as a function of time

Examples

1
2
3
4
ex_lsv = simulateLSV(e.start = 0.25, e.end = -0.25, e.form = 0,
  stir.rate = "fast", x.units = 100, t.units = 1000)
ex_lsvsample = sampleLSV(ex_lsv, data.reduction = 5)
str(ex_lsvsample)

Example output

List of 4
 $ expt     : chr "LSV"
 $ file_type: chr "reduced"
 $ current  : num [1:51] 0 0.00326 0.00481 0.0071 0.01048 ...
 $ potential: num [1:51] 0.25 0.24 0.23 0.22 0.21 0.2 0.19 0.18 0.17 0.16 ...

eChem documentation built on May 2, 2019, 2:14 p.m.