You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am wondering how to view the quality metrics, computed by spike interface, in Phy. Ideally for each unit in Phy, I would be able to see its computed quality metric scores.
I understand that one can create a sorting analyzer, and compute certain values within that, but I can't see how to associate metrics with a sorting analyzer object, for example.
Thanks,
The text was updated successfully, but these errors were encountered:
An easy way to do this is to extract the quality metrics as a DataFrame, then save this to a cluster_something.tsv file. Assuming you alreay have a SortingAnalyzer with metrics computed, should be able to do this as follows:
import pandas as pd
# Create sorting analyzer here
quality_metrics = analyzer.extensions['quality_metrics'].data["metrics"]
quality_metrics.index.name = 'cluster_id'
quality_metrics.to_csv(phy_folder / 'cluster_metrics.tsv', sep='\t')
By default, phy should load columns from any .tsv files it finds in the folder named cluster_xxxx.tsv, with cluster_id as an index column. One thing to note with this approach is that these are not computed dynamically, so if you split or merge units the values won't update for any new cluster IDs.
@twheatcroft07 actually if the SortingAnalyzer has the quality_metrics extension, each metric should alreayd be saved as a TSV file and available in Phy:
Hi there,
I am wondering how to view the quality metrics, computed by spike interface, in Phy. Ideally for each unit in Phy, I would be able to see its computed quality metric scores.
I understand that one can create a sorting analyzer, and compute certain values within that, but I can't see how to associate metrics with a sorting analyzer object, for example.
Thanks,
The text was updated successfully, but these errors were encountered: