Browse Source

[single cell ephys] started explore example file

Jan Grewe 5 years ago
parent
commit
b48544784d
1 changed files with 21 additions and 0 deletions
  1. 21 0
      single_cell_intracellular_spikes/explore.py

+ 21 - 0
single_cell_intracellular_spikes/explore.py

@@ -0,0 +1,21 @@
+import nixio as nix
+import matplotlib.pyplot as plt
+import numpy as np
+import os
+
+
+def metadata_overview(nf):
+  
+  for s in nf.sections:
+    s.pprint(depth=-1)
+  
+
+if __name__ == "__main__":
+  example_file = "2018-11-05-ab-invivo-1.nix"
+  if not os.path.exists(example_file):
+    print("Example file was not found")
+    exit()
+  nix_file = nix.File.open(example_file, nix.File.ReadOnly)
+  metadata_overview(nix_file)
+  nix_file.close()
+