Extracts a single channel from a multichannel 'emg' object
Extracts a specific channel from a multichannel ‘emg’ object.
an ‘emg’ object.
the specific channel to be extracted. Possible values: a character vector specifying the name of the channel to be considered (case sensitive) or a numeric value specifying the channel to be considered (number of column in
a string specifying the name of the variable which will appears on the plots. If empty or not provided is taken from the object given as
channel is a single channel ‘emg’ object, that single channel is returned as the output.
an ‘emg’ object containing a single channel.
J.E. Macias-Diaz, J.A. Guerrero email@example.com
1 2 3 4 5 6 7 8 9 10 11 12 13 14
# Load a data.frame with EMG data data(emg96627009) # Coerce a data.frame into an 'emg' object x <- as.emg(emg96627009) # Extract the second channel in x y <- extractchannel(x, 2) # Plot the data in y plot(y, main = "Second channel of emg96627009") # Extract the channel 'ENG-FDL' in x (third channel) z <- extractchannel(x, "ENG-FDL") # Plot the data in z plot(z, main = "Third channel of emg96627009")
Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.