Skip to content

Releases: donishadsmith/neurocaps

0.21.1

10 Jan 22:18
Compare
Choose a tag to compare

🐛 Fixes

  • Better type validation for fd_threshold and dummy_scans.

📖 Documentation

  • Slightly clearer documentation on the criteria used for fd_threshold.

Full Changelog: 0.21.0...0.21.1

0.21.0

02 Jan 22:25
Compare
Choose a tag to compare

🚀 New/Added

  • Added a new parameter, slice_time_ref in TimeseriesExtractor.get_bold to allow onset to be
    subtracted by slice_time_ref * tr if desired.

Full Changelog: 0.20.0...0.21.0

0.20.0

01 Jan 02:58
Compare
Choose a tag to compare

🚀 New/Added

  • Added new log message specifying the condition being extracted if condition is not None.
  • Added a new parameter, condition_tr_shift in TimeseriesExtractor.get_bold to allow a shift in the
    the starting and ending scan in TR units for a condition.

Full Changelog: 0.19.4...0.20.0

0.19.4

25 Dec 02:30
Compare
Choose a tag to compare

📖 Documentation

  • Links are fixed in the documentation.

🐛 Fixes

  • Fix indexing error for visualize_bold if parcel_approach["Custom"]["nodes"] is a NumPy array instead of list.

♻ Changed

  • Internally, the verbose parameter is set to 0 for nilearn's fetch_atlas_aal and fetch_atlas_schaefer.
    and the behavior is stated in the documentation. Cosine similarity in this case is assigned np.nan
  • When creating "regions" for the "Custom" parcel approach, both a list and range can be accepted. Previously, only
    lists were accepted.

List method:

parcel_approach["Custom"]["regions"] = {
    "Primary Visual": {"lh": [0], "rh": [180]},
    "Early Visual": {"lh": [1, 2, 3], "rh": [181, 182, 183]},
    "Dorsal Stream Visual": {"lh": list(range(4, 10)), "rh": list(range(184, 190))},
    "Ventral Stream Visual": {"lh": list(range(10, 17)), "rh": list(range(190, 197))},
    "MT+ Complex": {"lh": list(range(17, 26)), "rh": list(range(197, 206))},
    "SomaSens Motor": {"lh": list(range(26, 31)), "rh": list(range(206, 211))},
    "ParaCentral MidCing": {"lh": list(range(31, 40)), "rh": list(range(211, 220))},
    "Premotor": {"lh": list(range(40, 47)), "rh": list(range(220, 227))},
    "Posterior Opercular": {"lh": list(range(47, 52)), "rh": list(range(227, 232))},
    "Early Auditory": {"lh": list(range(52, 59)), "rh": list(range(232, 239))},
    "Auditory Association": {"lh": list(range(59, 67)), "rh": list(range(239, 247))},
    "Insula FrontalOperc": {"lh": list(range(67, 79)), "rh": list(range(247, 259))},
    "Medial Temporal": {"lh": list(range(79, 87)), "rh": list(range(259, 267))},
    "Lateral Temporal": {"lh": list(range(87, 95)), "rh": list(range(267, 275))},
    "TPO": {"lh": list(range(95, 100)), "rh": list(range(275, 280))},
    "Superior Parietal": {"lh": list(range(100, 110)), "rh": list(range(280, 290))},
    "Inferior Parietal": {"lh": list(range(110, 120)), "rh": list(range(290, 300))},
    "Posterior Cingulate": {"lh": list(range(120, 133)), "rh": list(range(300, 313))},
    "AntCing MedPFC": {"lh": list(range(133, 149)), "rh": list(range(313, 329))},
    "OrbPolaFrontal": {"lh": list(range(149, 158)), "rh": list(range(329, 338))},
    "Inferior Frontal": {"lh": list(range(158, 167)), "rh": list(range(338, 347))},
    "Dorsolateral Prefrontal": {"lh": list(range(167, 180)), "rh": list(range(347, 360))},
    "Subcortical Regions": {"lh": list(range(360, 393)), "rh": list(range(393, 426))},
}

List and range method:

parcel_approach["Custom"]["regions"] = {
    "Primary Visual": {"lh": [0], "rh": [180]},
    "Early Visual": {"lh": [1, 2, 3], "rh": [181, 182, 183]},
    "Dorsal Stream Visual": {"lh": range(4, 10), "rh": range(184, 190)},
    "Ventral Stream Visual": {"lh": range(10, 17), "rh": range(190, 197)},
    "MT+ Complex": {"lh": range(17, 26), "rh": range(197, 206)},
    "SomaSens Motor": {"lh": range(26, 31), "rh": range(206, 211)},
    "ParaCentral MidCing": {"lh": range(31, 40), "rh": range(211, 220)},
    "Premotor": {"lh": range(40, 47), "rh": range(220, 227)},
    "Posterior Opercular": {"lh": range(47, 52), "rh": range(227, 232)},
    "Early Auditory": {"lh": range(52, 59), "rh": range(232, 239)},
    "Auditory Association": {"lh": range(59, 67), "rh": range(239, 247)},
    "Insula FrontalOperc": {"lh": range(67, 79), "rh": range(247, 259)},
    "Medial Temporal": {"lh": range(79, 87), "rh": range(259, 267)},
    "Lateral Temporal": {"lh": range(87, 95), "rh": range(267, 275)},
    "TPO": {"lh": range(95, 100), "rh": range(275, 280)},
    "Superior Parietal": {"lh": range(100, 110), "rh": range(280, 290)},
    "Inferior Parietal": {"lh": range(110, 120), "rh": range(290, 300)},
    "Posterior Cingulate": {"lh": range(120, 133), "rh": range(300, 313)},
    "AntCing MedPFC": {"lh": range(133, 149), "rh": range(313, 329)},
    "OrbPolaFrontal": {"lh": range(149, 158), "rh": range(329, 338)},
    "Inferior Frontal": {"lh": range(158, 167), "rh": range(338, 347)},
    "Dorsolateral Prefrontal": {"lh": range(167, 180), "rh": range(347, 360)},
    "Subcortical Regions": {"lh": range(360, 393), "rh": range(393, 426)},
}

Full Changelog: 0.19.3...0.19.4

0.19.3

09 Dec 03:01
Compare
Choose a tag to compare

🚀 New/Added

  • Method chaining for several methods in the CAP and TimeseriesExtractor class.

Full Changelog: 0.19.2...0.19.3

0.19.2

06 Dec 07:17
Compare
Choose a tag to compare

🐛 Fixes

  • Add type hints to properties.
  • Improve accuracy of type hints for the properties.
  • Fixes type hints for certain parameters that included numpy.ndarray.
  • Replaces any returns that implies a plot object is returned and replaces with None for clarity.
  • Raise type error when self.subject_table in CAP is set but is not a dictionary.

Full Changelog: 0.19.1...0.19.2

0.19.1

30 Nov 19:22
Compare
Choose a tag to compare
  • Primarily to ensure all the latest distributions have the correct documentation links.
  • Includes some internal code changes that won't change results.
  • TODO for future version is to support Python 3.13.

0.19.0

29 Nov 02:26
Compare
Choose a tag to compare
  • Cleaning some of the API, specifically parameter names and properties, no defaults have been changed in
    this update.

🚀 New/Added

  • suffix_filename added to CAP.caps2plot, CAP.caps2surf, CAP.caps2radar, and transition_matrix.
    This addition was done to allow the suffix_title parameter in each of the previously listed methods to only be
    responsible for the title of the plots. The suffix filename will also be appended to the end of the default filename.

  • CAP class now has a cluster_scores property to consolodate the inertia, davies_bouldin, silhouette,
    and "variance_ratio" scores into a property instead of separate properties. Consequently, the inertia,
    davies_bouldin, silhouette, and "variance_ratio" have been removed.

The structure of this property is:

{
    "Cluster_Selection_Method": str,  # e.g., "elbow", "davies_bouldin", "silhouette", or "variance_ratio"
    "Scores": {
        "GroupName": {
            2: float,  # Score for 2 clusters
            3: float,  # Score for 3 clusters
            4: float,  # Score for 4 clusters
        },
    }
}

♻ Changed

  • Any instance of file_name in a parameter name has been changed to the more conventional parameter name filename.
    For instance, suffix_file_name now becomes suffix_filename and file_names becomes filenames. This
    change effects the following functions: merge_dicts, standardize, change_dtypes, CAP.calculate_metrics,
    CAP.caps2niftis, TimeseriesExtractor.timeseries_to_pickle, and TimeseriesExtractor.visualize_bold.
  • Warning logged whenever file name parameter is used but output_dir is not specified.

📖 Documentation

  • Fix doc parameter error for CAP.caps2niftis that used suffix_title instead of suffix_file_name, which
    is now suffix_filename.
  • In documentation, version labels restricted to changes or additions make from 0.18.0 and above for less clutter.

0.18.11

27 Nov 21:16
Compare
Choose a tag to compare

🐛 Fixes

  • An error in a setter method that did not use raise.

Full Changelog: 0.18.10...0.18.11

0.18.10

27 Nov 17:59
Compare
Choose a tag to compare

🚀 New/Added

  • Added deleter method for subject_timeseries and concatenated_timeseries properties

Full Changelog: 0.18.9...0.18.10