Science Score: 26.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (17.3%) to scientific vocabulary
Last synced: 10 months ago · JSON representation

Repository

Basic Info
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 10
  • Releases: 0
Created about 1 year ago · Last pushed 10 months ago
Metadata Files
Readme Changelog Contributing Security Codemeta

README.md

fmridataset

R-CMD-check Codecov test coverage lint pkgcheck CRAN status Lifecycle: experimental <!-- badges: end -->

Overview

fmridataset provides a unified framework for representing functional magnetic resonance imaging (fMRI) data from various sources. The package supports multiple data backends and offers a consistent interface for working with fMRI datasets regardless of their underlying storage format.

Features

  • Unified Interface: Work with fMRI data from NIfTI files, BIDS projects, pre-loaded NeuroVec objects, and in-memory matrices through a single API
  • Lazy Loading: Efficient memory management with on-demand data loading
  • Flexible Backends: Pluggable storage backends for different data formats
  • Data Chunking: Built-in support for processing large datasets in chunks
  • Temporal Structure: Rich sampling frame representation for run lengths, TR, and temporal organization
  • Integration Ready: Seamlessly integrates with neuroimaging analysis workflows

Installation

You can install the development version of fmridataset from GitHub with:

``` r

install.packages("devtools")

devtools::install_github("bbuchsbaum/fmridataset") ```

Quick Start

Creating Datasets

```r library(fmridataset)

From NIfTI files

dataset <- fmridataset( scans = c("run1.nii", "run2.nii"), mask = "mask.nii", TR = 2.0, runlength = c(240, 240) )

From in-memory matrix

matdata <- matrix(rnorm(1000), nrow = 100, ncol = 10) dataset <- matrixdataset( datamat = matdata, TR = 1.5, runlength = 100 )

From pre-loaded NeuroVec objects

dataset <- fmrimemdataset( scans = list(neurovec1, neurovec2), mask = mask_vol, TR = 2.0 ) ```

Data Access

```r

Get full data matrix

datamatrix <- getdata_matrix(dataset)

Get spatial mask

mask <- get_mask(dataset)

Access temporal properties

ntimepoints(dataset$samplingframe) nruns(dataset$samplingframe) getTR(dataset$samplingframe) ```

Data Chunking

```r

Process data in chunks

chunks <- datachunks(dataset, nchunks = 5) for (i in 1:5) { chunk <- chunks$nextElem() # Process chunk$data, chunk$voxelind, etc. }

Run-wise processing

runchunks <- datachunks(dataset, runwise = TRUE) run1data <- runchunks$nextElem() ```

Type Conversions

```r

Convert to matrix format

matdataset <- as.matrixdataset(dataset)

All dataset types support the same interface

print(dataset) summary(dataset$sampling_frame) ```

Architecture

The package uses a modular architecture with the following key components:

  • Storage Backends: Pluggable data access layer (matrix_backend, nifti_backend)
  • Dataset Constructors: High-level dataset creation functions
  • Sampling Frames: Temporal structure representation
  • Data Access Methods: Consistent interface for data retrieval
  • Chunking System: Efficient processing of large datasets

Related Packages

Getting Help

Contributing

Contributions are welcome! Please see our Contributing Guide for details.

License

GPL (>= 3)

Owner

  • Login: bbuchsbaum
  • Kind: user

CodeMeta (codemeta.json)

{
  "@context": "https://doi.org/10.5063/schema/codemeta-2.0",
  "@type": "SoftwareSourceCode",
  "identifier": "fmridataset",
  "description": "Provides a unified S3 class 'fmri_dataset' for representing functional magnetic resonance imaging (fMRI) data from various sources including raw NIfTI files, BIDS projects, pre-loaded NeuroVec objects, and in-memory matrices. Features lazy loading, flexible data access patterns, and integration with neuroimaging analysis workflows.",
  "name": "fmridataset: Unified Container for fMRI Datasets",
  "relatedLink": "https://bbuchsbaum.github.io/fmridataset/",
  "codeRepository": "https://github.com/bbuchsbaum/fmridataset",
  "issueTracker": "https://github.com/bbuchsbaum/fmridataset/issues",
  "license": "https://spdx.org/licenses/GPL-3.0",
  "version": "0.1.0",
  "programmingLanguage": {
    "@type": "ComputerLanguage",
    "name": "R",
    "url": "https://r-project.org"
  },
  "runtimePlatform": "R version 4.3.2 (2023-10-31)",
  "author": [
    {
      "@type": "Person",
      "givenName": "Bradley",
      "familyName": "Buchsbaum",
      "email": "bbuchsbaum@gmail.com",
      "@id": "https://orcid.org/0000-0001-5800-9890"
    }
  ],
  "maintainer": [
    {
      "@type": "Person",
      "givenName": "Bradley",
      "familyName": "Buchsbaum",
      "email": "bbuchsbaum@gmail.com",
      "@id": "https://orcid.org/0000-0001-5800-9890"
    }
  ],
  "softwareSuggestions": [
    {
      "@type": "SoftwareApplication",
      "identifier": "bidser",
      "name": "bidser",
      "sameAs": "https://github.com/bbuchsbaum/bidser"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "crayon",
      "name": "crayon",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=crayon"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "fmristore",
      "name": "fmristore",
      "sameAs": "https://github.com/bbuchsbaum/fmristore"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "foreach",
      "name": "foreach",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=foreach"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "testthat",
      "name": "testthat",
      "version": ">= 3.0.0",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=testthat"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "knitr",
      "name": "knitr",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=knitr"
    },
    {
      "@type": "SoftwareApplication",
      "identifier": "rmarkdown",
      "name": "rmarkdown",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=rmarkdown"
    }
  ],
  "softwareRequirements": {
    "1": {
      "@type": "SoftwareApplication",
      "identifier": "R",
      "name": "R",
      "version": ">= 4.3.0"
    },
    "2": {
      "@type": "SoftwareApplication",
      "identifier": "assertthat",
      "name": "assertthat",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=assertthat"
    },
    "3": {
      "@type": "SoftwareApplication",
      "identifier": "colorplane",
      "name": "colorplane",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=colorplane"
    },
    "4": {
      "@type": "SoftwareApplication",
      "identifier": "deflist",
      "name": "deflist",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=deflist"
    },
    "5": {
      "@type": "SoftwareApplication",
      "identifier": "memoise",
      "name": "memoise",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=memoise"
    },
    "6": {
      "@type": "SoftwareApplication",
      "identifier": "methods",
      "name": "methods"
    },
    "7": {
      "@type": "SoftwareApplication",
      "identifier": "neuroim2",
      "name": "neuroim2",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=neuroim2"
    },
    "8": {
      "@type": "SoftwareApplication",
      "identifier": "purrr",
      "name": "purrr",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=purrr"
    },
    "9": {
      "@type": "SoftwareApplication",
      "identifier": "tibble",
      "name": "tibble",
      "provider": {
        "@id": "https://cran.r-project.org",
        "@type": "Organization",
        "name": "Comprehensive R Archive Network (CRAN)",
        "url": "https://cran.r-project.org"
      },
      "sameAs": "https://CRAN.R-project.org/package=tibble"
    },
    "10": {
      "@type": "SoftwareApplication",
      "identifier": "utils",
      "name": "utils"
    },
    "SystemRequirements": null
  },
  "fileSize": "913.456KB",
  "releaseNotes": "https://github.com/bbuchsbaum/fmridataset/blob/master/NEWS.md",
  "readme": "https://github.com/bbuchsbaum/fmridataset/blob/main/README.md",
  "contIntegration": [
    "https://github.com/bbuchsbaum/fmridataset/actions/workflows/R-CMD-check.yaml",
    "https://app.codecov.io/gh/bbuchsbaum/fmridataset?branch=main",
    "https://github.com/bbuchsbaum/fmridataset/actions/workflows/lint.yaml",
    "https://github.com/bbuchsbaum/fmridataset/actions?query=workflow%3Apkgcheck"
  ],
  "developmentStatus": "https://lifecycle.r-lib.org/articles/stages.html#experimental"
}

GitHub Events

Total
  • Issues event: 1
  • Issue comment event: 7
  • Push event: 148
  • Pull request review event: 1
  • Pull request event: 100
  • Create event: 51
Last Year
  • Issues event: 1
  • Issue comment event: 7
  • Push event: 148
  • Pull request review event: 1
  • Pull request event: 100
  • Create event: 51

Issues and Pull Requests

Last synced: about 1 year ago

All Time
  • Total issues: 0
  • Total pull requests: 41
  • Average time to close issues: N/A
  • Average time to close pull requests: 1 minute
  • Total issue authors: 0
  • Total pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 38
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 41
  • Average time to close issues: N/A
  • Average time to close pull requests: 1 minute
  • Issue authors: 0
  • Pull request authors: 1
  • Average comments per issue: 0
  • Average comments per pull request: 0.0
  • Merged pull requests: 38
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • github-actions[bot] (1)
Pull Request Authors
  • bbuchsbaum (100)
  • dependabot[bot] (1)
Top Labels
Issue Labels
Pull Request Labels
codex (99) dependencies (1) github_actions (1)

Dependencies

DESCRIPTION cran
  • R >= 4.0.0 depends
  • iterators * imports
  • methods * imports
  • tibble * imports
  • bidser * suggests
  • foreach * suggests
  • knitr * suggests
  • neuroim2 * suggests
  • purrr * suggests
  • rmarkdown * suggests
  • testthat >= 3.0.0 suggests
.github/workflows/R-CMD-check.yaml actions
  • actions/checkout v4 composite
  • r-lib/actions/check-r-package v2 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/lint.yaml actions
  • actions/checkout v4 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/pkgcheck.yaml actions
  • ropensci-review-tools/pkgcheck-action main composite
.github/workflows/pkgdown.yaml actions
  • JamesIves/github-pages-deploy-action v4.5.0 composite
  • actions/checkout v4 composite
  • r-lib/actions/setup-pandoc v2 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/style.yaml actions
  • actions/cache v3 composite
  • actions/checkout v4 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite
.github/workflows/test-coverage.yaml actions
  • actions/checkout v4 composite
  • codecov/codecov-action v4 composite
  • r-lib/actions/setup-r v2 composite
  • r-lib/actions/setup-r-dependencies v2 composite