import_ABF_file()
is a wrapper around abftools::abf2_load()
and
abftools::MeltAbf()
. It converts the array from abf2_load()
into a
dataframe, and it also converts time to minutes.
Arguments
- file_name
Filepath to an
.abf
file (e.g. "Data/23711004.abf")- recording_mode
The mode used for the recording. If in
recording_mode = "voltage_clamp"
(e.g. clamping cell at -70 mV and measuring current amplitude) the primary channel (chan1
) is set to"current"
and the secondary channel (chan2
) is"voltage"
. Ifrecording_mode = "current_clamp"
, these values are reversed, where the primary channel is"voltage"
and the secondary channel is"current"
.
Value
A dataframe with 5 columns:
time
Time value from Clampfit which is in milliseconds x 10. For example, 5 seconds = 50000 in this column.episode
Character value (e.g. "epi1", "epi2") which corresponds directly to "sweep" in Clampfit.current
Current in pA.voltage
Voltage in mV.time_sec
Time in seconds.
Details
The file progresses from .abf
to an array and then to a dataframe that can be
easily manipulated in R. Be sure to assign a value to the dataframe so you can use it in later functions.
Examples
import_ABF_file(import_ext_data("sample_abf.abf"), recording_mode = "voltage_clamp")