Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
R
 
 
 
 
man
 
 
 
 
 
 
 
 
 
 

README.md

melviewr

Rdoc

Overview

This R package provides a graphical user interface (GUI) whose purpose is to view and classify the results of a MELODIC analysis in order to train the ICA+FIX classifier.

This package is an attempt to reimplement the Melview project in R, as installation of that viewer is sometimes difficult.

Installation

Stable releases of the melviewr package can be installed from the CRAN repository. First, make sure that GTK is installed on your system. Next, open R either in a terminal or through RStudio and type the following:

install.packages('melviewr', dependencies = TRUE)

To view examples of how to use the GUI, do:

library(melviewr)
?melviewr

You can install the most up-to-date version of the package by doing the following in R:

install.packages('devtools', dependencies = TRUE)
devtools::install_github('AndrewPoppe/melviewr')

You can also specify a particular release version when installing from github by appending a @ and the release tag name, i.e.:

devtools::install_github('AndrewPoppe/melviewr@v0.0.1')

Release tag names can be found by clicking on the Releases link on this page and then looking on the left hand side to find the tag name of the release you're interested in: TAG.

Other Usage

In addition to running the command from within R interactively, you can also write a shell script to open the GUI directly from the terminal (if you are using Linux or Mac). Something like the following should work, assuming melviewr has already been installed. Just save the following code to a file called "melviewr" and use chmod to make it executable. Then, put it somewhere in your PATH.

#! /usr/bin/env Rscript

args <- commandArgs(TRUE)

if (length(args) == 0) {
	writeLines("
melviewr: A MELODIC Viewer

Usage: melviewr <melodic output directory> -mot <motion file> -std <standard>

    -mot    Optional. The path to a single column motion file, such as a 
            Relative RMS or a column of FD values.
    -std    Optional. The path to a standard Nifti file on which to display the 
            MELODIC results. The voxel dimensions of this file must match those 
            of the melodic_IC.nii.gz file within the melodic output directory.

For more information, visit https://github.com/AndrewPoppe/melviewr
")
	q()
}

library(melviewr)

motion_file <- NULL
standard_file <- NULL

if (length(args) > 2) {
	for (i in 2:(length(args)-1)) {
		if (args[i] == "-std") standard_file <- args[i + 1]
		if (args[i] == "-mot") motion_file <- args[i + 1]
	}
}
		
melviewr(args[1], standard_file, motion_file)

Getting Help

Please email Andrew Poppe at Poppe076 at gmail.com

About

A viewer program for MELODIC output and ICA+FIX

Resources

Packages

No packages published

Languages