| find.subjectsdir.of | R Documentation |
Try to find directory containing the fsaverage subject (or any other subject) by checking in the following places and returning the first path where it is found: first, the directory given by the environment variable SUBJECTS_DIR, then in the subir 'subjects' of the directory given by the environment variable FREESURFER_HOME, and finally the base dir of the package cache. See the function download_fsaverage if you want to download fsaverage to your package cache and ensure it always gets found, no matter whether the environment variables are set or not. Note that a subject directory in the package cache is only considered complete if it contains the essential files of a subject, see subject.dir.has.core.files: the cache can contain a subject which only has some atlas files (see download_fsaverage_atlases), and such a directory would make all functions that need the surfaces of the subject fail.
find.subjectsdir.of(subject_id = "fsaverage", mustWork = FALSE)
subject_id |
string, the subject id of the subject. Defaults to 'fsaverage'. |
mustWork |
logical. Whether the function should with an error stop if the directory cannot be found. If this is TRUE, the return value will be only the 'found_at' entry of the list (i.e., only the path of the subjects dir). |
named list with the following entries: "found": logical, whether it was found. "found_at": Only set if found=TRUE, the path to the fsaverage directory (NOT including the fsaverage dir itself). "found_all_locations": list of all locations in which the subject directory exists, including locations at which the subject is incomplete (see the description). See 'mustWork' for important information.
fsaverage.path
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.