{"id":31936222,"url":"https://github.com/bbuchsbaum/fmriar","last_synced_at":"2025-10-14T07:25:20.428Z","repository":{"id":315407876,"uuid":"1059360181","full_name":"bbuchsbaum/fmriAR","owner":"bbuchsbaum","description":null,"archived":false,"fork":false,"pushed_at":"2025-09-18T12:07:34.000Z","size":1133,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-18T13:26:27.111Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://bbuchsbaum.github.io/fmriAR/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bbuchsbaum.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-18T10:42:46.000Z","updated_at":"2025-09-18T12:03:59.000Z","dependencies_parsed_at":"2025-09-18T21:03:16.649Z","dependency_job_id":null,"html_url":"https://github.com/bbuchsbaum/fmriAR","commit_stats":null,"previous_names":["bbuchsbaum/fmriar"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/bbuchsbaum/fmriAR","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bbuchsbaum%2FfmriAR","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bbuchsbaum%2FfmriAR/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bbuchsbaum%2FfmriAR/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bbuchsbaum%2FfmriAR/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bbuchsbaum","download_url":"https://codeload.github.com/bbuchsbaum/fmriAR/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bbuchsbaum%2FfmriAR/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279018215,"owners_count":26086303,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-14T02:00:06.444Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-14T07:25:19.437Z","updated_at":"2025-10-14T07:25:20.415Z","avatar_url":"https://github.com/bbuchsbaum.png","language":"R","readme":"# fmriAR\n\nfmriAR provides fast AR/ARMA-based prewhitening for fMRI GLM workflows. It estimates voxel-wise or parcel-based noise models, applies segment-aware whitening, and exposes diagnostics that make it easy to confirm residual independence.\n\n## Key capabilities\n- Automatic AR/ARMA order selection via Hannan–Rissanen initialization and iterative refinement (Hannan \u0026 Rissanen, 1982)\n- Segment-aware whitening that respects run boundaries and optional multiscale pooling across parcels\n- Convenience helpers to whiten design matrices, refit GLMs, and inspect autocorrelation diagnostics\n\n## Installation\n\n```r\n# install.packages(\"remotes\")  # only needed once\nremotes::install_github(\"bbuchsbaum/fmriAR\")\nlibrary(fmriAR)\n```\n\n## Quick start\n\n```r\n# X: design matrix (n x p), Y: voxel data (n x v), runs: factor or integer run labels\nres   \u003c- Y - X %*% qr.solve(X, Y)                      # pre-fit residuals\nplan  \u003c- fit_noise(res, runs = runs, method = \"ar\",    # estimate AR model\n                   p = \"auto\", pooling = \"global\")\nxyw   \u003c- whiten_apply(plan, X, Y, runs = runs)         # whiten design and data\nfit   \u003c- lm.fit(xyw$X, xyw$Y)\nse    \u003c- sandwich_from_whitened_resid(xyw$X, xyw$Y, beta = fit$coefficients)\nac    \u003c- acorr_diagnostics(xyw$Y - xyw$X %*% fit$coefficients)\n```\n\nSee `vignettes/` and `?fit_noise` for more detailed workflows, including multiscale pooling and ARMA whitening.\n\n## References\n\n- Hannan, E. J., \u0026 Rissanen, J. (1982). Recursive estimation of mixed autoregressive-moving average order. *Biometrika*, 69(1), 81–94.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbbuchsbaum%2Ffmriar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbbuchsbaum%2Ffmriar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbbuchsbaum%2Ffmriar/lists"}