segment.subconductance_as: Imposes a fixed conductance level (0 or 1) to all dwells with...

Description Usage Arguments Value Examples

Description

The user specifies the desired level ('open' or 'closed'). The function will modify any subconductance level (that is not 0 or 1) to be the desired level 1 for 'open' or 0 for 'closed'. The function then reutrns a collapsed segment containing alternating dwells. (See segment.consecutives_to_dwells for details about the collapsed segment.)

Usage

1
segment.subconductance_as(segment, level)

Arguments

segment

the segment containing dwells and states.

level

either 'open' or 'closed'

Value

A modified copy of the original segment

Examples

1
2
3
4
5
6
# It's more likely that you created states or dwells with some function
states  <-  c(0,    0.2,    0,    1,    0,  0.5,    0,  0.7,    0,    1)
dwells  <-  c(0.1,  1.1,  0.5,  0.2,  1.0,  1.1,  0.6,  1.1,  0.8,  1.1)
my_burst <- segment.create(states, dwells, seg=1, start_time=3.14159, name="example_segment")

my_burst_d <- segment.subconductance_as(my_burst, "open")

scbursts documentation built on July 6, 2019, 5:02 p.m.