#-------------------------------------------------------------
# Document Screen Width (bk = SetDocScreenWidth): #
#110##
#-------------------------------------------------------------

Funlist (\r\rdoc\funlist.htm).  List of functions in jmfuns.rda. 

 

Notes:

    SUGGESTIONS FOR REVISING Jmfuns.rda:  See ‹\r\jmfuns.revisions.docm

    \r\notes\funlist.v.jmfuns.docm  contains R-code for comparing whether funlist.htm has brief documentation for every function in jmfuns.rda. 

 

Function List:  Not all of the functions in this list are currently in jmfuns.rda.

Keyword

Archived/
Current

.First function

`first`initial

curr

.First.local is a function that resides in the local data.rda.  The JM .First function is designed to run this function at startup.

`first`local

curr

aaa.readme is a dummy function for giving identifying information about jmfuns.rda.

 

curr

all.pairs takes a vector x as input and returns all pairs of elements of x.  Optionally it can return all pairs of non-identical elements.

 

curr

animal.year yields the chinese zodiac. 

 

curr

aov.contrast function computes t-tests for contrasts in a univariate anova with  possibly many factors.  Contrasts can be defined in terms of the coefficients (weights)  that apply to the marginal means with respect to a designated factor. 

anova, contrast

curr

arch.rec is used to create a record of files that have been archived using ZTree.  It works in combination with ZTree.  It creates a text file with the record of files formatted conveniently for input to a Word table. 

`archive`Ztree

curr

area.under  function shades the area under a curve or between two curves.

integration, area

curr

array.to.df function takes an array as input, and outputs a dataframe that has the array entries as its first column, and factors that code the array dimensions. 

convert array to dataframe

curr

as.num.mat converts a matrix of string variables to a numeric matrix provided that every string is a series of digits, e.g., "5.3" is a string that represents 5.3.

converts string representations of numbers to numbers

curr

 

 

 

 

 

 

attach.jm attaches a list, dataframe or file to the search path in position = pos  if and only if the list, dataframe or file exists in the designated location and the list, dataframe or file is not already attached to the search path in any position.

 

curr

bayes.rule computes posterior probabilities given prior probabilities and likelihoods.

`bayes

curr

bb.rec projects the current baseball win/loss  record to a 162 game season. 

baseball

curr

bmi computes the Body Mass Index.

 

curr

brugs.chains extracts chains of samples from BRugs output.  Note that brugs.chains only works when the BRugs output is active, i.e., during the same session as the R session that created the BRugs output.

BUGS, BRugs

curr

bstats computes full season baseball stats given year-to-date stats.

 

curr

btt is an alias for the 'bringToTop' function.  It is used to bring a particular graphics window into focus. 

`graphics

curr

bugs.var has been deprecated in favor of the extract.vars function.  Use the latter function.  bugs.var extracts one or more posterior distributions from bugs output.  If bu is the output of a call to bugs within R, then bu$sims.array is an array that contains the WinBUGS results for all of the saved parameters.  bugs.var extracts the posteriors for one or more save parameters from output like bu.

BUGS, WinBUGS, R2WinBUGS

arch

bugs.ver specifies which version of OpenBUGS to use in a call to the bugs function in the R2OpenBUGS package.

BUGS

curr

c.to.f function converts Centigrade to Fahrenheit.

 

curr

cap.names transforms names like 'SMITH, JOHN THOMAS' to 'Smith, John Thomas'.

 

curr

cat.mds is an alias for cat(makeDisplayString(...)) - it prints a string vector to the computer screen.

 

curr

censor is a function for sampling from a censored distribution.

sampling, censored distribution

curr

charSubMatch takes two strings as arguments and returns TRUE if one of the strings is a part of the other string; otherwise it returns FALSE.  E.g., charSubMatch("abcdef", "cde") returns TRUE because cde is a substring of abcdef.  Similarly, charSubMatch("cde", "abcdef") returns TRUE.  charSubMatch("ace", "abcdef") returns FALSE because the string ace is not a substring of abcdef, nor is abcdef a substring of ace.

`match`strings

curr

check.all.fns checks whether all functions in a designated file, test.file, call only functions that are general purpose R functions or else are other functions in test.file.  It returns a list of functions that called by each function in test.file that are (i) not general purpose R functions and (ii) are not in test.file and (iii) are in avoid.file (usually 'jmfuns.rda').  check.all.fns uses the find.fn.in.fn function to check whether a given function calls another function. 

function files

curr

check.dups checks for any duplicates in a vector of names or filenames.  If duplicates are found, they are listed.  check.dups can also check whether filenames are duplicated in several different directories. 

duplicate file names, duplicate names

curr

chmat.to.dframe converts a character matrix to a dataframe.  chmat.to.dframe allows the user to designate which columns are retained as string vectors, which columns are converted to factors, and which columns are converted to numerical vectors.

convert character matrix to dataframe

curr

ci.bugs finds the limits of an alpha level credible interval.  The input is a vector of parameter values.  The output are the lower and upper bounds of the credible interval.  The interval can be computed either as an approximate highest density interval (HDI) or with equal probability tails.

BUGS, credible interval, confidence interval, HDI

curr

citytime function

 

curr

Cliffs.d computes the d statistic that is defined in Cliff (1993).  Optionally, it also computes other relevant statistics like sd2 (see documentation below for more information about additional statistics).  'Cliffs.d' uses Cliff's Eq. 2 to compute 'd', and it uses Cliff's Eq. 9 to compute sd2.

 

curr

cm.matrix takes anova or ancova output created by a call to lm or aov as input, and a matrix that transforms the vector of coefficient estimates to a vector of (adjusted) cell means for the anova factorial design.  If lm.input was computed with k factors and m covariates (possibly m = 0), where fk is the number of levels of the k-th factor, then lm.input$coef is a vector of length P(fk) + m, and lm.input$coef %*% cm.matrix(lm.input) is also a vector of length P(fk) + m, where the first P(fk) elements are the adjusted means for the anova design, and the last m elements are the regression coefficients for the m covariates.  Note that this order of coefficients, (adjusted cell) means first followed by covariates, need not be the same as the order of coefficients in lm.input$coef.

 

curr

cmptrStatus reports the current state of computerID, jmBrowser (jmBrowser), on.jm.cmptr.

`computer id

 

cnv.bytes converts between different units of bytes.

bytes, kilobytes, megabytes, gigabytes

curr

col.ranges returns the numeric codes for ranges of columns that are designated by column names, e.g., if xx is a matrix or dataframe with names, 'a', 'b', 'c', ..., 'z', then col.ranges(xx, from = 'b', to = 'e') returns 2:5.  'col.ranges' also operates on multiple ranges, e.g., col.ranges(xx, from = c('b', 'm', 'u'), to = c('e', 'p', 'x')) returns c(2:5, 13:16, 21:24). 

 

curr

colorChart function makes a plot showing colors that are available in R and the correspondence between these colors and number codes for the colors.

 

curr

colors.jm displays color codes, color names and sample colors in a graphics window.

 

curr

compare.files takes 2 path specifications, d1 and d2, as inputs, and returns a list with 3 components: (i) files in d1 that are not in d2; (ii) file in d2 that are not in d1; and files that are in both d1 and d2.

compare files

curr

computerID function returns "x220" (alias for "SPARSEGREY") when running R on the X220 laptop; it returns "uhouse" when running R on the UHouse computer; it returns "jcthinkpad" when running R on JC's Thinkpad; it returns "unknown" when it is running on any other computer.

 

 

conflicts.jm function is like the conflicts() function except that that by default, it shows all objects and not just the ones that start with a character, e.g., not ".First".  In addition, it displays the location on the search path of the conflicted objects. 

 

curr

contrast.coefs computes contrast coefficients for a multifactor between-subjects anova with arbitrarily many factors.  The input specifies the contrast coefficients in terms of a particular factor(s), and the contrast.coefs computes the  corresponding coefficients that are distributed over all remaining factors. 

 

curr

convert converts one system of units to another system of units.  This function is still under construction.

convert grams, ounces, pounds, meters, ...

curr

convertsToNum tests whether a string vector contains any non-numeric strings, e.g., "abc" or "18 years" are non-numeric strings; "123", "1.25", "-3", "-3.14", "", and "NA" are all treated as numeric strings.  is.numeric converts the strings, "" and "NA", to NA.  Note that a non-numeric string like "abc" will also convert via is.numeric to NA.

`read data`string`numeric

curr

copy copies an object from one environment on the search path (source) to another environment (target) on the search path. The object remains in the source environment after it has been copied; it also saves the target environment to its corresponding file.  The typical use of copy copies an object from .GlobalEnv to a file that is attached to the search path.  By default, the copy is not carried out if an object with the same name exists in the destination directory.  The default can be overridden (replace=T).  The copy function also applies to a character vector of object names.  The copy function is a wrapper for the move function with the default set to copy.only = TRUE. 

 

curr

copy.jmfuns copies jmfuns.rda to various locations.  It updates all versions of jmfuns.rda. 

copy jmfuns.rda

curr

copyFilesCurr copies the current list of files to corresponding directories on a flash drive.  The current list of files is maintained within the code for copyFilesCurr.

 

curr

cor.cor.test computes a z-test for a difference between correlated correlation coefficients, cor(aa, y) and cor(bb, y), where aa, bb and y are measurements on the same units (subjects). The test is based on formulas proposed in:  Meng, X., Rosenthal, R., & Rubin, D. B. (1992).  Comparing correlated correlation coefficients.  Psychological Bulletin, 111, 172-175.

correlated correlations

curr

cor.jm computes partial correlations between two or more variables after controlling for 0 or more other variables.  If the number of control variables is 0, then cor.jm computes correlations.   cor.jm is based on the pcor function due to Giovanni M. Marchetti.

correlation matrix, partial correlation matrix

curr

count returns the sample size of non-missing cases, or a vector showing the number of non-missing and missing cases. 

 

curr

cum.freq computes the cumulative frequency of the values of the input vector. 

 

curr

date.to.filename adds the current date of a file to the end of a file name.  E.g., if 'thisfile.doc' is currently dated 06/04/2012, then the file name is changed to 'thisfile.120604.doc'.  The function also applies to a vector of file names (with  or without paths). 

file date

curr

del.hdoc takes a path + file name as argument and deletes the html documentation for the document; the html documentation is stored in \aaaTravel\doc.nts and in a subdirectory.

delete, documentation

curr

del.types is used by 'ren&copy.del.docm' file to  rename a series of files.  'del.types' show paths+filenames for the 'del@*.*' files that are copied to file names in order to delete these files on both the home and office computers. 

 

curr

desc computes descriptive statistics.

 

curr

det.jm finds a file or package on the search path that matches the string argument.  It detaches this file or package.  Multiple input strings are permitted, thereby detaching multiple files in one operation.  Error messages are produced if the input strings have no matches or multiple matches on the search path.  

 

curr

dir.jm function lists files in a directory.  It accepts DOS wildcards.

 

curr

distribute.jm uses aggregate to compute a function value for each subset of an input variable X, where the subsets are defined by the combinations of an index variable, Index.  The output of distribute.jm is a vector out of the same length as X where out[k] = z iff X[k] is part of a subset that produced z as value. 
This function has been deprecated in favor of
stats.by.

 

arch

doc searches for user-created documentation for an R object; the documentation is either an html document or an R string vector.

 

curr

Doc.Directory is a function that returns the directory that contains html documentation for user-defined functions.

 

curr

doc.directory is a function.  A version of this function is stored in jmfuns.rda.  It indicates that the doc function is in the '/r/jmfuns.rda' file.  NOTE:  It is permissible to have other string or function objects named "doc.directory" that are stored in other files.

doc

curr

doc.tmplt is a template of a doc function (for documenting objects in a .rda file).  

 

arch

doc<- runs the default editor and opens a text file into which the user can type documentation for a dataframe or variable.  When the editor is exited, the text in the file is assigned to the doc attribute of an object in the form of a character vector.

 

arch

docBrowser [deprecated]  is a function that determines which browser is used to display 'doc' documentation.

 

curr

dotted.var.names is a function for recovering the variable names of variables that were inputted to functions through the "..." notation.

 

curr

dr [obsolete] is used to create a path specification with the drive letter that is appropriate for the current computer.  Data files are in the E: drive on the office Dell and the MacXP, and are on the D: drive ontihe Samsung netbook (N120).  E.g., dr(`/mydata` yields e:/mydata as output on the MacXP or d:/mydata on the netbook.

default drive on current computer

arch

draw.beta draws a beta distribution with the specified parameters; if the drawing is suppressed, the function returns the coordinates for the plot of a beta distribution with specified parameters.

beta distribution

curr

draw.f draws an F distribution with the specified df's. 

 

curr

draw.gamma computes the X-Y coordinates for a gamma probability density function.  It either plots the function or simply outputs the coordinates.

gamma distribution

curr

draw.inv.gamma computes the X-Y coordinates for an inverse gamma probability density function.  It either plots the function or simply outputs the coordinates.

inverse gamma

curr

draw.normal computes the X-Y coordinates for a normal probability density function.  It either plots the function or simply outputs the coordinates.

normal distribution

curr

draw.phi draws the F (phi) distribution that corresponds to a specified normal distribution with mean m and standard deviation s.

 

curr

draw.t draws a t distribution with the specified Df.  Optionally it draws in the t observed and the area corresponding to the  p-value, or the critical value and the alpha level. 

t distribution

curr

drive.letter [eliminate this function: 10/24/2013] function returns the drive letter ("C:" or "D:") for the current session.  See also dr.  See also R.version and Sys.getenv( "COMPUTERNAME" ) which can be better ways to identify the current computer and its configuration. 

 

curr

ellipse.jm makes an ellipse at the specified center, width and  height. 

 

curr

encode.nums creates a memorable code number from a number.

code number

curr

entropy function computes the entropy of a finite probability vector or the entropy of each row of a matrix.

 

curr

env.to.pos function

 

curr

eq.jm and neq.jm are similar to == and != except that the return FALSE when either argument is missing (but TRUE when both arguments are missing).

 

curr

eq.strings tests for the equivalence of strings after stripping off selected characters like blank spaces.

 

curr

error.bars adds error bars to an existing plot.  This function replaces superpose.eb, which is now obsolete (4/23/2010).

error bars

curr

eval.jm

 

curr

exists.jm checks that each of a series of named objects exists on the search path.

exists

curr

export.spss exports an R matrix or data frame to SPSS.   export.spss writes the data to a text file, and creates a SPSS syntax file that can be used within SPSS to load the data. 

 

curr

extract.chains function extracts the chains of estimates from the sims.array component of a bugs run (bugs function in R2WinBUGS package).

bugs, WinBUGS, R2WinBUGS, chains, MCMC

curr

extract.constant  takes a vector input and returns the single non-missing value of the vector if there is one.  If the input has multiple non-missing value, then an error is generated.

extract value, stratum values

curr

extract.dir1 takes a path+(optional)filename as input and returns the first non-root directory in the path.  

`path`directory

curr

extract.extension takes a vector of file names and returns the extensions of every file.  Note that file names can be preceded by paths but the paths must use / or \\ and not \ to indicate subdirectories.

file names

curr

extract.filename extracts the file name from a string that indicates the path + file name.

file names

curr

extract.filename.only takes a character vector of Window's file names possibly including paths, and returns the vector of file names without paths.  The file extensions are removed.

file names

curr

extract.lastname extracts the last name from a string like "Smith, John David".  It can also extract the given names.

person names

curr

extract.path extracts the path from a string that indicates the path + file name.  extract.path is similar to the 'dirname' function in the standard R installation, but there are cases where they differ.  See doc( extract.path ) for a description of the differences. 

path

curr

extract.vars extracts one or more posterior distributions from bugs output.  If bu is the output of a call to bugs within R, then bu$sims.array is an array that contains the WinBUGS results for all of the saved parameters.  extract.vars extracts the posteriors for one or more save parameters from output like bu.

BUGS, WinBUGS, R2WinBUGS

curr

f.to.c function converts Fahrenheit to Centigrade.

 

curr

factor.codes displays the correspondence between factor codes and their numeric values.

 

curr

fakeNonJM_ID sets the following functions to return values that make it seem as if R is not running on one of JM's computers:  jmBrowser, on.jm.cmptr, computerID.  fakeNonJM_ID replaces these functions with fake functions that prevent jmfuns.rda functions from identifying JM's computers.  It is useful to be able to disguise JM's computers as non-JM computers when working on functions like doc that are designed to operate differently on JM's computers and on non-JM computers.   The cmptrStatus function reports the current state of computerID, jmBrowser, on.jm.cmptr.  The code for fakeNonJM_ID is in \r\fns\disguiseJM.cmptrs.docm .

`computer id

 

file.copy.jm is like the file.copy function except that it allows the function to compare the current date of the files.  If date.check = TRUE (default), then the source file is copied to the target file only if the last modification of the source file is more recent than the last modification of the target file.  file.copy.jm creates a destination folder if it does not already exist.

copy files

curr

file.exists function is stored in jmfuns.rda.  It masks the Base file.exists function.  The only difference from the Base function is that if it is called while working on one of JM's computers, it reinterprets the path specification to be appropriate for the particular computer.  If it is called while working on a non-JM computer, it simply calls the Base file.exists function.

 

 

find.fn.in.fn creates a vector of all function names for all functions called by a designated function such that the called functions are in a designated avoid.file and are not in a designated test.file.  Usually, this function is called to check whether a function calls any functions that are in jmfuns.rda that are not in jm.utilities.rda.  find.fn.in.fn is used by check.all.fns.

 

curr

findDocDocmDocx finds files that are in the same directory and have the same file name except for differing .doc, .docm, or .docx file extensions.  If one of the names in the group has a .docm or .docx extension and another has a .doc extension, than the .doc path+file name is written to an output file.  These path+file names can be loaded from file to be deleted on both the PS.Spirit and X220 computers.

 

curr

fnCodeFdbkAnte and fnCodeFdbkPost help the user write function code.  These functions precede and follow, respectively, the main function code.  They provide feedback to the user with regard to whether the main function code has actually succeeded in creating a function (as opposed to a failure where a previous copy of the function might still exist in .GlobalEnv).

`function coding

curr

foot function is the inverse of the 'head' function.  It displays the last 5 rows of a matrix or dataframe or the last 5 elements of a vector.  Deprecated in favor of the tail function. 

 

arch

from.mcmc.list takes a list of chains of class MCMC and returns a list of chains with one component per parameter.  Each component is a matrix whose columns are the chains for that parameter.

 

curr

func takes a n x 2 matrix, and interprets it as a function.

 

curr

funlist is a dummy function that is loads the funlist.htm webpage into the default browser. . 

doc

curr

gamma.parameters returns the parameters of a gamma distribution, given a subset of the parameters, e.g., if given the shape and rate parameters, it returns the mean, sd, variance, and scale parameters.

gamma

curr

geomean computes the geometric mean of a vector.

 

curr

Get.Vars function is like get.vars except that it takes the output of v.names as input and a specification of data, dv, factor or quant, and returns a dataframe with all of the specified variables. 

 

curr

get.vars function takes a character vector vn of variable names, the name d.frm of a dataframe, and a boolean vector bool  that is TRUE when vn[k] is in the dataframe and FALSE when vn[k] is not on the dataframe but is on the search path.  get.vars returns a dataframe out in which out[,k] is the variable corresponding to vn[k] for every k.  (Comment:  The model component of an lm output object contains all of the variables in the lm call, so one can get the data from it as well, e.g., if lm.output is the name of the output of a call to lm, then lm.output$model has all of the relevant variables.  get.vars differs from lm.output$model in the case of a factor variable, Fac, that has a level with no non-missing data.  In this case, levels(lm.output$model[ , "Fac"], will not have the empty level (level with no data) as one of its levels whereas get.vars applied to Fac will have the empty level as one of its levels.  This is the main difference between get.vars and lm.output$model.) 

 

curr

getDrv takes a vector of directory names as input and returns the drives on which these directories reside.  On the PS.Spirit computer, a given directory may exist on several drives but it is only \"active\" on one drive.  getDrv returns the drive letter of the active drive for a directory.  If not working on a JM computer, it returns the drive letter that is returned with getwd().  If the input to getDrv includes a drive designation, e.g., if dirPath = "d:/abc/thisDoc.docm", then getDrv returns the drive letter "d:" regardless of which drives are the standard drives on the current computer.

`root directory

curr

grade.exam takes a vectors v1 and v2 as inputs and returns a graded exam as output.   v1 and v2 must be vectors of characters.  v1 is the vector of a student's answers to length(v1) questions, and v2 is the vector of correct answers.  Multiple correct answers are allowed for a single question in v2.  The default output is the number of correct answers in v1.  Optionally, the output can be a 3-column dataframe in which columns 1 and 2 are v1 and v2, respectively, and column 3 is 1 or 0 depending on whether each answer is correct or incorrect. 

grading

curr

HDIofMCMC was one of the functions downloaded from Kruschke's (2011) textbook website.  It computes an xx% highest density interval from MCMC simulation output. 

HDI, highest density interval, MCMC

curr

htmlDocList is a function that creates a vector of strings that represent possible html doc files for a given object name (o.name = "<name>").  The output strings include paths as well as file names.  Note that there may not exist an object named o.name, and there may not exist any html files that document this object.  htmlDocList returns the names of possible html doc files that do exist, or if there are no such files, it returns NULL.

doc

curr

iat.score computes the IAT score of an individual subject following the "improved algorithm" recommended in Greenwald et al. (2003), Table 4.  By default, 'iat.score' outputs a single number representing the IAT score for the selected subject.  Optionally, 'iat.score' outputs a vector of response latencies that have been modified as specified in the improved algorithm. 

 

curr

ifExistsRm function checks whether one or more objects exist in a specified environment.  If so, the objects are removed; if not, nothing happens.  By default, the user receives no feedback about the outcome of the operation, but feedback can be requested.

`rm

curr

import.s  Import an S-Plus object into R.

 

curr

import.spss reads an SPSS file, changes the variable names to lower case, and converts SPSS variables with value labels to factors.  If the SPSS variable has user missing values, or if an SPSS variable has value labels  for some but not all levels of the variable, then the variable is not converted to a factor.  Warning messages are sent to the user. 

 

curr

installed.packages.jm lists the packages that are installed on the computer that is currently running R.  installed.packages.jm produces a subset of the information that is outputted by the R-base function, installed.packages, but it formats the information in a way that is easier to grasp quickly.

 

 

is.digit tests whether an input string is a string of digits.  It yields TRUE if the input string consists entirely of digits, and FALSE otherwise.

 

curr

is.positive.definite tests whether a matrix is positive definite or positive semi-definite.  Optionally it returns information about whether the input matrix was symmetric and whether all eigen values were positive or non-negative.

`bayes`wishart

curr

iSep inserts a separator in RStudio output. 

`display

curr

j prints an R object to the screen without displaying its doc attribute.  This is useful because I store documentation in a doc attribute, but often it is preferable not to display the documentation when displaying the object.

 

arch

jm.utilities.cur is a vector of function names.  These are the main utility functions in jmfuns.rda.  This vector is used by the update.jm.utility.fns function.

 

curr

jmBrowser returns the path + file name for the browser program that John Miyamoto uses for loading html documents that are stored on the local hard drive.  If jmBrowser is called while R is running on a computer that is not one of John Miyamoto's computers, it returns the current R default browser, i.e., getOption("browser").

 

cirr

jmbugs.cur is the vector of names of JM's current utility functions for working with BUGS objects.

 

curr

jmfiles copies a designated list of files to 'my dropbox', '/inet/xxx', and other relevant locations.

file utility, update standard files

curr

jmfuns is a dummy function for displaying documentation for jmfuns.rda.  The 'jmfuns.doc' object is updated within the 'copy.jmfuns' function.

 

curr

km.mile converts measurements between kilometers and miles.

kilometers, miles, convert

arch

kruschke.files is simply a path to the directory where the .r files for Kruschke's textbook are stored. 

Kruschke

curr

kt.cumwt appears to compute the cumulative weighting function for the Kahneman/Tversky weighting function.  This function is old.  It needs to be checked, possibly revised.  4/27/2013

 

curr

kt.dwt appears to compute decision weights for a gamble according to the Kahneman/Tversky weighting function.  It allows for different weighting functions for gains and losses. This function is old.  It needs to be checked.

 

curr

ktwt  computes the transformed cumulative probability according to the Kahneman & Tversky (1992) functional.  kt.dwt computes the decision weights for a vector of probabilities, ordered from the probability of the worst to the probability of the best outcome. 

`probability weighting`decision weights

curr

last4 extracts the last 4 characters from a string.  It applies to a character vector to do the same for every component.  The main use of this function is to extract the last for digits of student ID's. Optionally, the 'num.char' argument can be used to return a different number of terminal characters than 4.

 

curr

lib.ini lets the user edit the list of packages that are loaded at startup. 

 

curr

Library.ini.3.0.0 is a list that shows which packages were installed by default with R 3.0.0 prior to installing any user-selected packages. 

 

curr

lin.coeff computes the slope and intercept of a linear regression line given the x and y coordinates of 2 points.  The slope and intercept define a line that goes through these two points.

 

curr

lin.fun computes the coefficients of a linear function that maps a given pair of points to a given pair of transformed values.

 

curr

LL.stat computes the log likelihood statistic (-2*log likelihood) from the model likelihood that is reported by the lme function.  Optionally, it also computes the AIC and BIC by means of the SPSS definition of these statistics as well as reporting these statistics as defined in R.

`AIC`BIC`SPSS`lme

curr

ls.jm outputs a vector of object names for objects in an environment on the search path.  It is essentially the same as ls except that the formatting is easier to work with. 

 

curr

ls.objects outputs information about objects in an environment.   there seems to be an error in the code, but where?  Deprecated. 

 

arch

Make.Names creates proper names from letter strings, e.g., converts SMITH, MAGGIE to Smith, Maggie.  Deprecated.  See cap.names. 

convert capitalized proper names to standard proper names.

arch

make.names.jm makes syntactically valid R names out of a character vector (as does the make.names function).  It differs from make.names insofar as terminal periods (.) are deleted if possible, and successive periods, e.g., "..", are optionally removed.

 

curr

makeDisplayString (alias mDS) takes a sequence of strings as input (via ...) and returns a string that has been formatted for display (application of the strwrap function).  See, also, the rIndent macro for creating nice code that looks good with makeDisplayString. 

 

 

curr

makeJmDrvDir.ls creates a list of matrices that display the correspondence between directories and drives on various JM cmputers.  Only the lowest directories (1st offspring of the root directory) are displayed.  makeJmDrvDir.ls creates a list named jmDrvDir.ls and places it (assign) in .GlobalEnv.  At present (1/31/2015), jmDrvDir.ls is only relevant to identifying the drives on the PS.Spirit computer.

`root directory

curr

matchString has two arguments:  inString is a vector of strings and testString is a vector of strings.  matchString returns a vector of strings of the same length as inString.  For inString[k], matchString returns the unique element of testString that matches inString[k] if it exists; if no matching element exists, it returns "**noMatch**"; if multiple matching elements exist, it returns "**multipleMatches**". 

`grep`match

curr

matrix.to.clipboard takes each entry in a string matrix, copies the entry to the clipboard, and pauses while the user pastes the entry into another program.  This is useful when sending feedback emails to students.

`grading`email

curr

mDS is an alias for the makeDisplayString function.  See the documentation for the makeDisplayString function.

 

curr

mean.jm is like mean except that the default is to remove missing values.  Deprecated.  Use mean( x, na.rm = TRUE ). 

 

arch

median.jm computes the sample median with an adjustment for tied scores at the median. If there are no tied scores at the median, median.jm and median are identical. If there are tied scores at the median, then median.jm computes an interpolated median that assumes a uniform distribution within the class interval that contains the median.   The formula for median.jm is median.jm(X) = L + ((N*.5 - B)/W)*i  where X is the sample, L is the lower real limit of the class interval that contains the median, N is the sample size, B is the number of observations strictly less than L, W is the number of observations that are tied at the class interval that contains the median, and i is the width of the interval that contains the median.  See Kirk's intro stat book or Jaccard & Becker for a discussion of this definition of the median. 

 

curr

merge.jm is just like merge except that by default, all = TRUE.  Deprecated.  Just add all = TRUE to the call to merge. 

 

arch

mk.onecode function:  This function takes a list of factors, all of equal length, and outputs  a single factor that enumerates the combinations of levels of the input factors.  The factor  levels of the input factors are incremented from the right. 

 

curr

mm.triangle makes a figure showing the Marschak-Machina triangle with good annotation.

 

curr

modal.value computes the modal value of a vector.  If there is more than one modal value, then it returns a vector with all of the modal values.

 

curr

move puts an R object from one environment on the search path to another environment on the search path.  By default, it deletes the object from the initial environment.  By default, the move is not carried out  if an object with the same name exists in the destination directory.  The  default can be overridden (replace.object=T).  The move function also applies to a character vector of object names. 

move objects

curr

mw.est computes Mann-Whitney estimates of  p  =  P(random obs from B > random obs from A)

 

curr

mw.test computes a Mann-Whitney U Test with Probability Estimates

 

curr

myfunsLoc returns the location of the John Miyamoto's function file, jmfuns.rda, if R is running on one of his computers.  Otherwise R queries the user for the location of a file that contains the user's functions.

`jmfuns

curr

n computes the length of a vector.  By default, it drops the missing cases and warns if there are missing cases.  Optionally, it returns a vector that shows the number of missing cases and the total number of cases.

n, sample size, length

curr

n.gt.1 takes a numeric variable (dv) and a list of factors and returns a variable that is identical to dv except that it is NA for every observation that is in a cell with only one non-NA observation.  This is useful when computing studentized deleted residuals for an anova because the studres and stdres functions in the MASS library (also, the rstudent function in the base library) sometimes gives the value » 0 to such observations.  They should always get the value of NA because their "hat" (hii) values should equal 1.0, and (1 - hii)-1 occurs in the computation of these residuals.

 

curr

n.unique computes the number of unique values of x.

 

curr

na.F has been deleted from jmfuns.rda as of 1/1/2010.  Use na.to.F instead. 
na.F takes a Boolean vector and returns a Boolean vector that is identical except that NA is replaced with FALSE, e.g., c(TRUE, FALSE, NA) is returned as c(TRUE, FALSE, FALSE).

 

arch

na.to.F converts a logical vector that may contain some NAs to a logical vector of the same length in which every NA is replaced with FALSE while leaving all existing TRUEs and FALSE's as they are.

NA converted to FALSE

curr

NA.to.F converts a logical vector that may contain some NA's to a logical vector of the same length in which every NA is replaced with FALSE while leaving all existing TRUE's and FALSE's as they are.

 

 

nameArgs returns the names of variables or arguments that are specified in the ... part of a function call.  E.g., suppose the function FF has arguments x, y and ..., so args(FF) returns <function(x, y, ...)>.  Also, suppose that nameArgs(...) is called within the body of the FF function.  If FF is called with the arguments FF(x = 3, y = 5, aa = "text", bb = 1:5, xpos = 3), then the call to nameArgs(...) within FF will return c("aa", "bb", "xpos").  The nameArgs function was defined in Venables and Ripley (2000; S Programming, p. 46).

`function definition

curr

ncp.f computes the ncp argument of the pf function (noncentral F distribution). 

 

curr

ncr computes "n choose r", i.e., it computes  (n!)/(r!)((n-r)!)  Don't need this function anymore.  Use the R choose function instead. 

 

arch

neq.jm and eeq.jm are similar to == and != except that the return FALSE when either argument is missing (but TRUE when both arguments are missing.

 

curr

nm replaces a vector with the same vector after removing all NA's. 

NA, remove missing values

curr

nm.df takes a dataframe DF as argument and returns a dataframe that is like DF except that all cases that are missing on any variable have been removed.  As of 4/27/2013, I can't find this file. 

NA, remove missing values from a dataframe

arch

normal.curve function outputs the coordinates of a normal curve with given mean and SD.  Deprecated in favor of draw.normal. 

 

arch

notRStudio is a function of 0-arguments.  It returns TRUE iff R is NOT running under RStudio. 

`rstudio

curr

nScreens sets the twoScreens object in jmfuns.rda to either TRUE or FALSE depending on whether R is configured for one computer monitor only or to two computer monitors.  nScreens configures R to run either for single monitor (X220 only) or dual monitor (Dell monitor + X220).

 

curr

nxt function resets the current graphics device either to a designated open graphics window, or to dev.next(), or it opens a graphics device if one isn't currently open. 

 

curr

o.type tests for the mode and factor or dataframe status of an object.

 

curr

ob.dir' is the path to the OpenBUGS program directory.  'wb.dir' is the path to the WinBUGS program directory. 'bugs.dir' is an obsolete name for the WinBUGS program directory - it has been reset to a reminder that now there are two choices, OpenBUGS and WinBUGS. 

 

curr

odds.to.p converts odds to probability where the Odds(X) = P(X)/(1 - P(X). 

`odds

curr

on.jm.cmptr is a boolean function.  It returns TRUE if R is running on one of JM's usual computers, and FALSE otherwise.  on.jm.cmptr() is used to enable special actions that are active when JM is working onone of his usual computers, and are inactive when working on any other computer.  See also 'myfunsLoc' function.  See also the computerID function. 

`computer id

curr

order.jm orders a matrix or dataframe by a series of columns.  It differs from the order function because it can take a matrix or dataframe as input (as opposed to a sequence of vectors).

`order

curr

packages.to.keep is a vector of package names to be installed in R 3.0.0.  These are packages that are not part of the default installation of R 3.0.0 but which were installed on JM's version of R 2.15.2.

 

curr

pad.right OBSOLETE

This function has been deprecated in favor of the 'format' function {base}.

 

Use 'format( ..., justify = "left")'

Old documentation:  pad.right adds blanks to the right of character strings to make every item in a character vector have the same number of characters.  After running 'pad.right', every item in the input vector will have as many characters as the longest item in the vector.

 

arch

pad.zero adds zeroes to the front of character strings (usually digit strings) if they are needed to make the strings be of a particular length.

 

curr

par.default has the default values of par.  Useful for resetting par settings to the initial default values.

 

curr

par.jm produces a graph with the JM's default par settings.    

 

curr

path.curr takes a path+filename specification and returns the full path + filename including the drive letter, e.g., "/aa/bb.rda" is returned as "e:/aa/bb.rda" on the X220 computer and as "b:/ab/john/aa/bb.rda" on Dad's computer.

 

curr

path.std (path standardized) converts a string that specifies a directory path into a string that specifies the same path with / as the path separator, e.g., e:\\data\\data.rda is converted to e:/data/data.rda.  This function is useful when checking whether two path specifications are identical other than differences in path separator, \\ or /.

`path specification

curr

pchlist lists the plotting characters.

 

curr

phi.f computes the f parameter of a noncentral F distribution,  where s is the common standard deviation, ni is the i-th sample size, mi is the i-th population mean,  m· is the grand mean, and r is the number of groups. 

 

curr

phone.num converts text numbers to phone numbers.

 

curr

pick.one takes a vector as input and returns the single, non-missing, unique value in the vector.  If there is more than one non-missing value in the vector, pick.one returns NA.  It is often useful in combination with the aggregate function. 

aggregate, unique

curr

plot.autocorr plots autocorrelations for a parameter that has one or more chains of samples from BUGS.

BUGS autocorrelation

curr

plot.chains plots the chains for parameters saved in a call to bugs.

 

curr

plot.jm creates a plot with JM's preferred settings.

`plot`graphics

curr

plot.window allows the user to set the active window without knowing the enumeration number for the window.  Deprecated in favor of the nxt function. 

Graphics windows, current graph, current window

arch

plotPost is one of John Krushke's functions for his 2011 textbook on Bayesian Data Analysis.

 

curr

power.f computes the power of an F test for a oneway between-subjects anova. 

 

curr

pphi computes the lower or upper tail probabilities of a phi distribution.

 

curr

prelec.wt computes the Prelec weighting function for a vector of cumulative probabilities.  Except for differences in notation, Eq. (3.2) of Prelec (1998) proposes the weighting function W(p)  =  exp(b(–log(p))a).  Prelec (1998) allows for different parameters b and a for the probabilities of gains and the probabilities of losses.  It is assumed that b > 0 and 0 < a < 1. 

 

curr

proper.name take a character vector, and returns a character vector with every element formatted like a proper name, i.e., first letter is capitalized, other letters are lower case.  Deprecated in favor of the cap.names function. 

proper names, character vector

arch

qphi computes the number in the phi scale (the [0, 1] interval) which has a cumulative or decumulative probability of p.  The phi distribution is the transformation of a N(mean, sd) distribution to the [0, 1] interval by means of the N(0, 1) cumulative distribution.

 

curr

qt.jm computes quantiles of the noncentral t distribution.

 

curr

r.ini resets the R session to the same search path as the one that is present at start up, and it empties the .GlobalEnv.

`initialize

curr

r_tbl_to_text is a Word macro that copies all R tables from the current location to the end of the file where they are converted to a text version of the R-code.  This macro is useful when converting R-code that is formatted within tables for a handout (Word document) into an R text source file.  Alias = 'rttt'. 

`R source file`.R file

curr

R2 is a function for reporting R2change in hierarchical regressions.   R2 creates a table showing R2 and R2change in a nested sequence of regressions. 

 

curr

r2z computes the Fisher's R to Z function.

 

curr

rank.seq assigns sequential ranks to unique values (similar to ties condense in SPSS). 

 

curr

rd.answerkey reads the answer key for an exam from a text file.  It is assumed that the file is delimited by blank spaces. 

grading

curr

rd.scorepak reads student data from a ScorePak file.  The input is a tab-delimted file.  Need to use Excel to convert file from Excel format to tab-delimited text file.

grading

curr

rd.tab.txt reads a text file that was saved in Excel as a tab-delimited text file.  It assumes that the data are a matrix except possibly for a header that has to be edited or removed.  The data are initially outputted as a long character vector (mmode = 1).  If mmode = 2, the data outputted as a character matrix.  If mmode = 3, the data are outputted as a dataframe.

read data file, text file, Excel

curr

recode Function recode recodes an input variable into a series of discrete values.  If cuts are used, the recoding includes  the right-hand boundary but not the left-hand boundary in  the recoding.  If pts are used, a series of input values  are recoded to a series of output values, but all input value that are not mentioned in the pts vector are left unchanged.  tol = the size of the absolute difference between the input x and pts in order for value of x to be recoded.  Set tol = -Inf to require exact equality.

 

curr

rectan plots a rectangle with specified corners.

 

curr

repos is a temporary function while I work out the bugs in the R version 2.0 startup procedure.

 

arch

res.param computes basic statistics for the prior or posterior distribution of a parameter in a WinBUGS analysis.  It plots the density of the parameter and displays credible intervals on the graph.

density plot, posterior distribution

curr

restore.path computes the path objects that are present on one search path (character vector) and absent on a second search path (character vector) and removes these objects (dataframes, files, packages) from the search path.

 

curr

restoreJMCmptrID function restores the status of jmfuns.rda functions to their usual setting where they correctly identify when R is running on one of JM's computers.  The functions that are restored are: jmBrowser, on.jm.cmptr, computerID.  fakeNonJM_ID sets the following function to return values that make it seem as if R is not running on one of JM's computers:  jmBrowser, on.jm.cmptr, computerID. The non-fake versions of these functions are stored in, jmBrowserNonFake, on.jm.cmptrNonFake, computerIDNonFake, respectively.  The cmptrStatus function reports the current state of computerID, jmBrowser, on.jm.cmptr.

`computer id

 

rIndent macro creates an indented paragraph whose indent equals the position created by the tabs at the beginning of the paragraph.  rIndent assumes that the paragraph is in one of the 'r' styles, e.g., 'r' or 'rred'.  Alias ri. 

`r

curr

rinteger computes a random integer between a lower and upper bound.  The probability mass function is uniform.

`random`integer

curr

rjags.chains extracts chains of samples for monitored parameters in a JAGS run that was produced by means of functions in the rjags package.  Q(4/27/2013): Is this function needed?  Has it been superceded by 'extract.chains'?

 

curr

rm.all removes all objects from .GlobalEnv.

remove

curr

rm.ifex removes one or more objects from the global environment AFTER checking whether the object exists.  The only advantage of rm.ifex over rm is that rm.ifex does not give an warning message if the specified object does not exist in .GlobalEnv.  Sometimes this helps to avoid visual clutter.

remove

arch

rm.sv removes (deletes) an object from an environment on the search path and saves that environment.  rm.sv also applies to a character vector of object names. 

remove

curr

rnorm.cut samples from a  censored N(mu0, sigma0) distribution.

censored normal

curr

roc.n function computes the values of an ROC curve.

 

curr

root.dir returns the root directory for the current computer.  root.dir() returns 'e:/' on the X220 laptop, and it returns 'b:/ab/john/' on Dad's computer.

 

curr

rotate rotates points through a specified angle around zero. 

 

curr

round.dfm  rounds the numeric variables in a dataframe to the specified number of digits.  Useful primarily for displays.

 

curr

rs.keys loads a webpage of RStudio shortcut keys from the RStudio.com website.  doc(rs.keys) loads a copy of this webpage on the local computer. 

 

curr

rs.shortcuts Function displays selected RStudio shortcut keys in the Viewer pane of RStudio. It should have no effect when R is running outside of RStudio.

`RStudio

curr

rsk function is an alias for rs.shortcuts function.

`RStudio

curr

rstudent.jm differs from rstudent only when computing an anova or ancova with lm, and only when some cells have only 1 observation.  Observations that are in cells with only one observation are always assigned an sdr of NA by rstudent.jm whereas rstudent sometimes assigns nonmissing sdrs to such observations. I.e., rstudent appears to make a mistake in this case. See e:\r\notes\studentized deleted residuals for a fuller explanation.  Need to check whether the current R has corrected this bug.  Deprecated - on 4/27/2013, JM could not find this file in jmfuns.rda. 

 

arch

samGraph is function that plots the successive samples from a specified distribution.  The purpose is to illustrate the idea of discovering the form of a distribution from samples from the distribution.

 

curr

save.jm is exactly like the R save function except that it checks whether the file exists.  If it does, then it won't save the object unless specifically instructed to do so.

 

curr

save.or.move saves one or more objects to a file if the file does not exist.  Otherwise it attaches the file to the search path and moves the objects to this file. 

 

curr

scor.bnd computes the bounds on scores that produce a particular academic grade. 

grades, grading

curr

screenFont is a function that sets the font size and screen size for the R console.  The font.size argument specifies a font size; number of rows and columns are adjusted to accomodate this font size.

Rconsole, display

 

sd.jm is like sd except that the default is to remove missing values.  Deprecated.  Use sd( x, na.rm = TRUE ). 

 

arch

set.packages loads packages at program startup.  It is used in combination with .First.

 

curr

setRepos sets the default repository from which to download R packages.

`packages

curr

setwd.jm sets the current working directory and attaches the associated 'data.rda' file, if one exists.  If no such file exists, then it creates such a file.

working directory

curr

sf function is an alias for the screenFont function.

Rconsole. display

 

show.bugs shows the main information about a bugs output object.

BUGS

curr

smry.spss computes summary statistics for lme output in SPSS format, i.e., converting R statistics produced by lme to the corresponding form of SPSS statistics.

`summary`lme`SPSS

curr

source.dBDA sources one of Kruschke's .R files, saves the contents to a temporary environment, and attaches the environment to the search path.

`Kruschke`source

curr

source.kr can be used to source Kruschke's .R files without making the directory that contains these files the current working directory.  source.kr solves the problem that some of Kruschke's .R files source other Kruschke .R files.  The latter sourcing causes errors when the current working directory is not the directory that contains the Kruschke's .R. 

`p548`kruschke

curr

special.jm.options functions set startup configurations that are peculiar to JM's work.  THESE COMMANDS SHOULD NOT CONTAIN ANY SETTINGS THAT WOULD CREATE DIFFERENCES BETWEEN JM'S R COMPUTATIONS AND THE STUDENTS' R COMPUTATIONS.  E.g., setting the R repository to Fred Hutch is ok because even without this setting, students' work will have equivalent effects.

`first

curr

spPos function returns the numeric positions of the matches between an input string, xString, and a string vector, searchWhat.  By default, searchWhat = search(), so the default behavior of spPos is to return the positions of matches to xString on the search path.  If no matches are found, spPos returns integer(0); if any matches are found, spPos returns a vector of all matching positions.

`search path`match

curr

SSq computes the sum of squares for a vector of numbers.  This function replaces the SS function which has been removed in order to preserve the principle that all double letters, e.g., aa, AA, bb, BB, etc., are unused by functions in R.

sum of squares

curr

stats.by uses aggregate to compute a function value for each subset of an input variable X, where the subsets are defined by the combinations of an index variable, Index.  

statistics, subsample, strata

curr

std.coef extracts standardized regression coefficients  (beta weights) from an lm object.  Function written by John Fox. 

 

curr

stripRoot strips the root for a path/file on one of JM's computers.  On other computers, it does nothing.

 

curr

stripWhite removes any leading or trailing white space from a string.  It can also apply element-wise to a string vector. 

`white space

curr

stripwhite strips leading and trailing white space from a string.

white space

curr

stu.id adds zeroes to the start of a student id that has had its initial zeroes stripped off.  E.g., it converts 35721 to 0035721.

 

curr

stu.res displays the exam answers and correct answers for an individual student for a given exam.  It also computes the total for multiple choice and true/false questions for the given students.

 

curr

superpose.eb adds error bars to a bar plot.  This function has been superceded by error.bars. 

error bars, bar plots

arch

sw.bugs switches the R configuration between OpenBUGS, WinBUGS and JAGS. It also loads one of the packages, BRugs, R2OpenBUGS, R2WinBUGS, rjags or R2jags, and unloads any of the other packages if they happen to be loaded onto the search path. 

BUGS, WinBUGS, OpenBUGS, JAGS

curr

SW.table makes a model comparison table like those shown in Singer and Willett (2003). 

`lme`output

curr

Sys.time.jm outputs current time as a string or as a character vector.

 

curr

system.time.jm is exactly like the system.time function in the base package except that the output is labeled in accordance with the Help documentation. 

 

curr

to.coda has been replaced with the function, to.mcmc.list. 

 

arch

to.mcmc.list takes a list that was created by a call to extract.chains and creates a list of class mcmc.list.  The functions in the coda package require inputs that are organized as an mcmc.list and have the mcmc.list class attribute.  Thus, the 'to.mcmc.list' function creates a list of chains that is suitable for analysis by using functions in the 'coda' package.

BUGS, coda, extract.chains

curr

tog.utilities detaches jmfuns.rda from the search path and attaches jm.utilities.rda to the search path, or vice vera, depending on the current state of the search path.

 

curr

togDisplay toggles the showDisplay variable; if it is TRUE it is set to FALSE; otherwise it is set to FALSE.

`display

curr

trim.blank removes leading or ending blank characters.  Deprecated in favor of strip.white. 

blanks

arch

trim.extension takes a character vector that represents a vector of Windows file name, and returns the vector with the file extensions removed, e.g., c('aaa.doc', 'bb cc.dat') is converted to c('aaa', 'bb cc').  Deprecated.  See extract.filename.only. 

`string`extension

arch

trt.coef.names computes a dataframe that shows the names of every coefficient when computing an anova or ancova with 'lm'. 

 

curr

u.cpt  Computes a value function for cumulative prospect theory. Value is a multiplicative function of duration and health state.   Value is a power function of duration.   Reference level duration (Xref) is given as input.  Value at duration=0 is computed.  (See u.cpt2 for complimentary function).  Info re variables at end of function definition. Xref:  ref level is utility achieved at (full health, Xref).  See also u.cpt2.  This is an unfinished revision of u.cpt. 

 

curr

u.exp  computes an exponential utility function. 

 

curr

u.power  computes a power utility function.

 

curr

UHouse.packages.2.15.2 : a list of current (4/26/2013) UHouse R packages when running R 2.15.2. 

 

curr

update.all copies a designated list of files to other directories where copies of these files are maintained.  E.g., the current version of jmfuns.rda is always kept in the \r directory, but copies of this file are maintained in other locations like \inet\jmfiles, \inet\p548, etc.  update.all makes sure that all mirrored versions of files are identical to their canonical versions, e.g., \r\jmfuns.rda, \cm\templats\jmmx.dotm, etc.  The update.all function supercedes the jmfiles function.

 

curr

update.jm.utility.fns updates JM's utility functions by copying the current version of these functions from 'jmfuns.rda' to 'jm.utilities.rda'.

jm.utilities.rda

curr

update.jmbugs updates the functions in e:/r/jmbugs.rda.  jmbugs.cur is a vector that names the functions that are currently kept in jmbugs.rda.

 

curr

v.names extracts the variable names from the output object of a call to lm.  The output of v.names is a dataframe with 3 columns  called Names, Type, and On.Dataframe.  Suppose that the dataframe has been assigned the name N.out.  Then  N.out$Names[1] = All vars on search path if the call to lm  did not have a data argument.  Otherwise, N.out$Names[1] is  the name of the dataframe that was assigned to the data argument of the lm call.  N.out$Names[2] is the name of the dependent variable, and N.out$Names[3] to N.out$Names[3 + k] are the names of the k+1 predictor variables.    N.out$Type[1] is always data.source, and N.out$Type[2] is  always dv.  For the remaining predictor variables, N.out$Type[i]  is either factor or quant depending on whether the variable is  treated as a factor or a quantitative variable.  N.out$On.Dataframe is TRUE for variables that are in the dataframe that was names by N.out$Names[1], and FALSE  otherwise (in which case the variable must have been on the  search path when lm was called. 

 

curr

varsToFile writes information about the variables in a dataframe to a text file.  Typically, this text file is then copied into a Word document where it is processed further.

`documentation

 

wb.dir is the path to the WinBUGS program directory. 'bugs.dir' is an obsolete name for the WinBUGS program directory - it has been reset to a reminder that now there are two choices, OpenBUGS and WinBUGS. 

 

curr

wb2ob.mod converts a WinBUGS model files to OpenBUGS model files. It is almost identical to the publically distributed R function Win2OpenBUGS.  The only difference is that wb2ob.mod allows the user to write a comment at the head of the resulting OpenBUGS model file; typically, this comment indicates the WinBUGS model that was the source of the OpenBUGS model file, although the user can write any comment that he or she chooses.

bugs, WinBUGS, OpenBUGS, model file

curr

wh.s takes the name of a file or package as input and returns the location in the search path at which that file or package is attached. 

 

arch

Win2OpenBUGS is a R function for converting WinBUGS model files to OpenBUGS model files.  It was downloaded from http://www.openbugs.info/w/UserContributedCode on 1/29/2011.

bugs, WinBUGS, OpenBUGS, model file

curr

windows.jm opens a graphics window.  It makes use of code from John Kruschke's openGraph function for opening a graphics window in a way that is compatible with either Windows, Mac or Linux OS. 

 

curr

write.function writes the R code for functions and .doc objects (character vectors) to a file in text format.  The code in the output file can be sourced to create the functions and .doc objects on another computer.

`write`code`functions

curr

write.functions writes the R code for functions and .doc objects (character vectors) to a file in text format.  The code in the output file can be sourced to create the functions and .doc objects on another computer.

 

curr

writeDframeVars takes a dataframe as argument.  It writes the variables in the dataframe to a string that identifies the type (numeric, string, factor, etc.) of each variable, and places this string on the clipboard.  This string can then be pasted into an html doc.

`rdoc

curr

X220.packages.2.15.2 is a list of current (4/26/2013) X220 R packages when running R 2.15.2.  After that date, the number of packages was reduced when JM upgraded to R 3.0.0. 

 

curr

ymd function returns the current date in yymmdd format.  Optionally it appends the time and returns yymmdd.hhiiss (where 'ii' is minutes).

date, time

curr

z.score takes a vector as input and returns the vector of z-scores.

 

curr

z2r computes the inverse of Fisher's R to Z function.

 

curr

zscore computes z-scores for the elements of a numeric vector. 

stats

curr

zzz.readme is a dummy function for giving identifying information about jmfuns.rda.

 

curr

 

 

 

 

 

------------------------

Format for this html document:

    Page Size = Tabloid:  11" x 17".  Note that Tabloid page size is available if Adobe PDF is set as the default printer, but not if the default pringer is a physical printer that prints 8.5" x 11" standard paper. 

    Table widths = 9.5"