,

Dependencies

  • dplyr and tidyr move from Imports to Suggests, so installing eeguana no longer installs them. The dplyr verbs still work on eeguana objects whenever dplyr is installed, because their methods are registered as soon as dplyr loads, whichever of the two packages loads first.

  • Examples and vignettes no longer load dplyr. The vignettes, and the one example that uses a verb from outside eeguana, load tidytable instead, a faster alternative.

  • purrr is no longer a dependency. ## Bugs fixed

  • drop_incomplete_segments() errored with could not find function "na.omit" on every call. It now drops the segments holding missing values, as documented.

  • transmute() on an events table errored with object 'transmute.tidytable' not found, because the tidytable method it called was removed upstream.

  • plot_topo() accepts any data frame. It previously had a method only for tibbles, so a plain data.frame had none.

  • read_vhdr() now checks the .dat against its header before reading it. A file that is too short, usually an incomplete copy or download, stops with both sizes named instead of failing inside data.table with Supplied 38410 items to be assigned to 38409 items of column '.id'. A file that is too long warns and is read in full.

Breaking

  • eeg_interpolate_tbl() returns a tidytable rather than a tibble. It is still a data frame, so it keeps working wherever one is expected, but a test such as inherits(x, "tbl_df") on the result is now FALSE.

Internal

  • eeguana no longer sets data.table keys. Printed tables lose their Key: line.
  • dplyr is no longer called inside the package. The internal calls go through tidytable, and the calls that act on an eeg_lst go through eeguana’s own eeg_* generics.
  • dev/check_without_dplyr.R runs the package on a library where dplyr, tidyr, and tibble are not installed.
  • No unexported function of another package is called with ::: any more. One such call had already broken transmute() on events tables when tidytable removed the function.

New features

  • read_edf() gains .trigger_channel, for EDF files that record triggers as an ordinary channel rather than as annotations. Name the channel, or use "last" for the last one. Its values become events and it is dropped from the signal table. When the argument is left out and the last channel looks like triggers, a message says so.

Bugs fixed

  • read_ft() and read_set() failed with invalid substring arguments on files with an empty text field. The cause is a regression in R.matlab 3.8.0; Remotes: points at R.matlab’s development version until the fix reaches CRAN.
  • read_fif() and as_eeg_lst() on an MNE object no longer fail with KeyError: 'bad'.
  • The join verbs now take copy in dplyr’s position, so left_join(x, y, by, copy) no longer lands on suffix, and semi_join()/anti_join() no longer reject copy. copy and extra arguments are ignored with a warning.
  • keep = NULL, dplyr’s default for the joins, no longer errors. keep = TRUE warns and is ignored: it would split .id, which ties the signal, events and segments tables together.
  • ungroup(x = data) works. The method took its first argument as .data while dplyr’s generic calls it x.
  • annotate_events() no longer warns about ggplot2’s deprecated %+%.

Internal

  • Guards in eeg_summarize() and the validate_*_tbl() functions against a data.table::setcolorder() bug affecting tables with 64 or more columns. The validators now return their table instead of working by reference.
  • S3 methods registered in NAMESPACE; no change to the public API.
  • Documentation regenerated with roxygen2 8.0.0.
  • Large test files moved out of the package sources into a per-user cache; see dev/README.md.
  • Tests no longer write to the package sources or the user’s home directory.
  • Updated documentation
  • Signal table format consistent

Bug fixed

  • could not find function "across." error fixed (thanks @prattems)

New Features

  • Added chs_mean method for psd_list objects.
  • Introduced experimental read_fif() function to read fif files created by MNE Python.
  • New install_py_eeguana() function to install the necessary Python packages for reading fif files.

Bugs and Improvements

  • Improved behavior of channel_dbl and sample_int classes.
  • Enhanced annotate_events() function to allow plotting even if there are no events.
  • fix installation of the dependency tidytable.
  • added annotate_electrodes() to add electrode labels to a topographic plot. (Previously this was done with geom_text()).
  • fix of minor bug affecting eeg_artif_step(), when the number of samples in window was odd.
  • as_eeg_lst() makes eeg_lst objects created with previous versions of eeguana compatible with the current version.
  • New features:
  • The argument .ref of eeg_rereference() now allows “tidyselect”.
  • Modifying channels with channels_tbl() is much faster now.
  • Signal filtering is slightly faster and uses the gsignal package.
  • BUGS:
    • some brainvision files produced by eeglab couldn’t be read now work
  • DEPRECATIONS:
    • The argument .all_chs of eeg_events_to_NA was deprecated in favor of the more flexible .n_chs.
  • Breaking change: _at, _if, _all functions don’t work anymore. Now one should use the new across() (or across_ch()) notation. If your code doesn’t work anymore and you don’t know how to fix it, please post it in https://github.com/bnicenboim/eeguana/discussions
  • Potential breaking change: when segments with repeated columns are joined, they use data.table notation (i...) rather than dplyr notation. This might affect the join family and eeg_segment.
  • dplyr-like functions get an eeg_ prefix (e.g., eeg_mutate, eeg_filter), they still work without the prefix (for now).
  • NEW FEATURES:
    • filters have more options (including IIR, experimental).
    • read eeglab set files (still experimental)
  • documentation:
    • more examples
  • internal changes:
    • removed dependency with stringr
    • changed internal structure of eeg_lst, the segments table is a data.table rather than a tibble and they depend on tidytable
  • Bugs:
    • weird dplyr filter behavior fixed #136
  • Changes
    • plot_components() behaves more similarly to plot_topo()
    • BREAKING CHANGE ... are always the second argument and most arguments require now a . at the beginning: This should help to differentiate them from channels.
  • Improvements
    • New examples for ICA functions.
    • Much faster mutate functions
    • Better error messages for reading Brain Vision files @jaromilfrossard
    • scale works properly for channels now
  • Additions
  • Bugs: tons of compatibility issues with dplyr 1.0
  • Changes
    • Signal processing functions added sig_fft(), sig_ifft().
    • Better print method for channels.
    • More consistent events_tbl with obligatory .type and .description
  • More unit testing.
  • Bugs:
    • read_edf() wasn’t reading events from the status channel
    • fixed some inconsistencies with .reference argument
  • Changes
    • New vignette that introduces the package here.
    • FastICA was implemented in eeg_ica().
    • Artifact detection functions in eeg_artif_*().
    • Filters were greatly improved and checked, only FIR filters are supported for now, based on MNE.
    • Better documentation (mostly Kate Stone).
    • Easy access to the information of the different tables with signal_tbl(), events_tbl(), and segments_tbl().
    • Changes in the creation of eeg_lst objects.
    • Faster as_tibble().
    • as.data.table() was added.
    • Renamed functions:
  • Bugs
    • Events in Brain Vision version 1.0 file are now correctly read.
    • Various minor bugs fixed.
  • Changes
  • Bugs
  • Internal changes:
    • Better test structure.
    • Better validation of objects.
  • Changes
    • chs_fun() to apply arbitrary functions to the channels.
    • Fieldtrip tutorial added as a vignette.
  • Bugs
    • Channels appear in the right order in plots.
    • Other minor bugs.
  • Changes
    • ggplot2 theme improved.
    • changed the default downsampling in plots.
    • better handling of weird channel names.
    • segment() accepts initial and final segments.
    • summarize adds a summarize_n column.
    • events function to visualize and edit events was added.
    • various filters were added.
  • Bugs
    • ch_rereference updates the relevant attributes.
    • bugs in various reading functions were fixed (int encoding issues).
    • mutate recognize better channels.
    • *_join functions fixed.
  • Signals table is now powered by data.table.
  • Added a NEWS.md file to track changes to the package.