supereeg.
Model
(data=None, locs=None, template=None, numerator=None, denominator=None, n_subs=None, meta=None, date_created=None, rbf_width=20, save=None)[source]¶Model data object for the supereeg package
This class holds your supereeg model. To create an instance, pass a list of brain objects and the model will be generated from those brain objects. You can also add your own model by passing a numpy array as your matrix and the corresponding locations. Alternatively, you can bypass creating a new model by passing numerator, denominator, locations, and n_subs (see parameters for details). Additionally, you can include a meta dictionary with any other information that you want to save with the model.
Parameters: |
|
---|---|
Returns: |
|
Attributes: |
|
Methods
get_locs () |
Returns the locations in the model |
get_model ([z_transform]) |
Returns a copy of the model in the form of a correlation matrix |
get_slice (loc_inds[, inplace]) |
Indexes brain object data |
info () |
Print info about the model object Prints the number of electrodes, number of subjects, date created, and any optional meta data. |
plot_data ([savefile, show]) |
Plot the supereeg model as a correlation matrix This function wraps seaborn’s heatmap and accepts any inputs that seaborn supports for models less than 2000x2000. |
plot_locs ([pdfpath]) |
Plots electrode locations from brain object |
predict (bo[, nearest_neighbor, ...]) |
Takes a brain object and a ‘full’ covariance model, fills in all |
save (fname[, compression]) |
Save method for the model object The data will be saved as a ‘mo’ file, which is a dictionary containing the elements of a model object saved in the hd5 format using deepdish. |
set_locs (new_locs[, force_include_bo_locs]) |
update self.locs to a new set of locations (and blur the correlation matrix accordingly). if |
update (data[, inplace]) |
Update a model with new data. |
__init__
(data=None, locs=None, template=None, numerator=None, denominator=None, n_subs=None, meta=None, date_created=None, rbf_width=20, save=None)[source]¶Methods
__init__ ([data, locs, template, numerator, ...]) |
|
get_locs () |
Returns the locations in the model |
get_model ([z_transform]) |
Returns a copy of the model in the form of a correlation matrix |
get_slice (loc_inds[, inplace]) |
Indexes brain object data |
info () |
Print info about the model object Prints the number of electrodes, number of subjects, date created, and any optional meta data. |
plot_data ([savefile, show]) |
Plot the supereeg model as a correlation matrix This function wraps seaborn’s heatmap and accepts any inputs that seaborn supports for models less than 2000x2000. |
plot_locs ([pdfpath]) |
Plots electrode locations from brain object |
predict (bo[, nearest_neighbor, ...]) |
Takes a brain object and a ‘full’ covariance model, fills in all |
save (fname[, compression]) |
Save method for the model object The data will be saved as a ‘mo’ file, which is a dictionary containing the elements of a model object saved in the hd5 format using deepdish. |
set_locs (new_locs[, force_include_bo_locs]) |
update self.locs to a new set of locations (and blur the correlation matrix accordingly). if |
update (data[, inplace]) |
Update a model with new data. |