Package munfold. R topics documented: February 8, Type Package. Title Metric Unfolding. Version Date Author Martin Elff

Similar documents
Package EnQuireR. R topics documented: February 19, Type Package Title A package dedicated to questionnaires Version 0.

Package fso. February 19, 2015

Package mixphm. July 23, 2015

Package sciplot. February 15, 2013

Package feature. R topics documented: October 26, Version Date

Package lvm4net. R topics documented: August 29, Title Latent Variable Models for Networks

Package qrfactor. February 20, 2015

Package feature. R topics documented: July 8, Version Date 2013/07/08

Package kofnga. November 24, 2015

Package hsiccca. February 20, 2015

The nor1mix Package. June 12, 2007

Package sspline. R topics documented: February 20, 2015

Package areaplot. October 18, 2017

The nor1mix Package. August 3, 2006

Package r2d2. February 20, 2015

Package gains. September 12, 2017

Package waterfall. R topics documented: February 15, Type Package. Version Date Title Waterfall Charts in R

Package beanplot. R topics documented: February 19, Type Package

Package GLDreg. February 28, 2017

Package prettygraphs

Package multigraph. R topics documented: January 24, 2017

Package Binarize. February 6, 2017

Package Mondrian. R topics documented: March 4, Type Package

Package clustering.sc.dp

Package kdevine. May 19, 2017

Package JBTools. R topics documented: June 2, 2015

Package FCGR. October 13, 2015

Package mpm. February 20, 2015

Package MeanShift. R topics documented: August 29, 2016

Package multigraph. R topics documented: November 1, 2017

Package gibbs.met. February 19, 2015

Package visualizationtools

Package cgh. R topics documented: February 19, 2015

Package ICSOutlier. February 3, 2018

Package replicatedpp2w

Package dissutils. August 29, 2016

Package tclust. May 24, 2018

Package CLA. February 6, 2018

Package JOP. February 19, 2015

Package pca3d. February 17, 2017

Package MatrixCorrelation

Package asymmetry. February 1, 2018

Package rknn. June 9, 2015

Package pathdiagram. R topics documented: August 29, 2016

Package robustreg. R topics documented: April 27, Version Date Title Robust Regression Functions

Package Rwinsteps. February 19, 2015

Package R2SWF. R topics documented: February 15, Version 0.4. Title Convert R Graphics to Flash Animations. Date

Package sglr. February 20, 2015

Package GCAI.bias. February 19, 2015

Package sankey. R topics documented: October 22, 2017

Package spd. R topics documented: August 29, Type Package Title Semi Parametric Distribution Version Date

Package optimus. March 24, 2017

Package panelview. April 24, 2018

Package mlegp. April 15, 2018

Package desplot. R topics documented: April 3, 2018

Package desire. R topics documented: February 19, Version Title Desirability functions in R

Package glogis. R topics documented: March 16, Version Date

Package RCEIM. April 3, 2017

Package Daim. February 15, 2013

Package nonmem2r. April 5, 2018

Package CINID. February 19, 2015

Package seg. February 15, 2013

AA BB CC DD EE. Introduction to Graphics in R

Package abf2. March 4, 2015

Package Rambo. February 19, 2015

Package qvcalc. R topics documented: September 19, 2017

Package ClustGeo. R topics documented: July 14, Type Package

Package nlsrk. R topics documented: June 24, Version 1.1 Date Title Runge-Kutta Solver for Function nls()

Package InPosition. R topics documented: February 19, 2015

Package EMC. February 19, 2015

Package basictrendline

Package kdetrees. February 20, 2015

Package ExceedanceTools

Package nprotreg. October 14, 2018

Package pampe. R topics documented: November 7, 2015

Package cumseg. February 19, 2015

Package flam. April 6, 2018

Package sizemat. October 19, 2018

Package RaPKod. February 5, 2018

Package pendvine. R topics documented: July 9, Type Package

Package SmoothHazard

Package weco. May 4, 2018

Package alphashape3d

Package mmeta. R topics documented: March 28, 2017

Package sbf. R topics documented: February 20, Type Package Title Smooth Backfitting Version Date Author A. Arcagni, L.

Package smoothr. April 4, 2018

Package logspline. February 3, 2016

Package ALS. August 3, 2015

Package gee. June 29, 2015

Package naivebayes. R topics documented: January 3, Type Package. Title High Performance Implementation of the Naive Bayes Algorithm

Package SparseFactorAnalysis

Package beast. March 16, 2018

Package dyncorr. R topics documented: December 10, Title Dynamic Correlation Package Version Date

Package MFDFA. April 18, 2018

Package MPCI. October 25, 2015

Package MixSim. April 29, 2017

Package orthogonalsplinebasis

The sspline Package. October 11, 2007

Package hbm. February 20, 2015

Package pso. R topics documented: February 20, Version Date Title Particle Swarm Optimization

Transcription:

Package munfold February 8, 2016 Type Package Title Metric Unfolding Version 0.3.5 Date 2016-02-08 Author Martin Elff Maintainer Martin Elff <martin@elff.eu> Description Multidimensional unfolding using Schoenemann's algorithm for metric and Procrustes rotation of unfolding results. License GPL-2 LazyLoad Yes Imports memisc, MASS, stats, graphics URL http://www.elff.eu/software/munfold/,http://github.com/melff/munfold/ NeedsCompilation no Repository CRAN Date/Publication 2016-02-08 23:32:37 R topics documented: procrustes.......................................... 2 unfold............................................ 2 Index 6 1

2 unfold procrustes Procrustes Rotation Description Usage procrustes performs procrustes rotation, at the moment only of unfold solutions. procrustes(x,...) ## S3 method for class unfolding procrustes(x, use=attr(x,"procrustes_use"), target,...) Arguments x Value use target an object the components of which to rotate., which of the components of x should be used as criterion for rotation. a matrix to which the rotation criterion should be brought as close as possible.... further arguments for future methods, currently ignored. a copy of x with components appropriately rotated. unfold Metric Unfolding Description Usage unfold computes a metric unfolding solution based on a rectangular matrix, that is, reconstructs two sets of points from the distances between points of the first set and the points of the second set. uapply applies a function the two point sets that are reconstructed by unfold. unfold(x,...) ## S3 method for class matrix unfold(x, ndims=null, squared=false, tol=1e-7, method=c("schoenemann", "CG"),...) ## S3 method for class formula unfold(x,data=parent.frame(),...)

unfold 3 ## S3 method for class unfolding biplot(x, dimen=c(1,2), type=attr(x,"biplot_type"), xlim, ylim, tpos=c(4,2), tposdim=1, asp=1, lty=c(1,2), lwd=c(1,1), pch=c(1,3), cex=c(1,1), col=c("black","black"), contour.col="black", contour.lty=1, xlab=paste("dimension ",dimen[1]), ylab=paste("dimension ",dimen[2]),...) ## S3 method for class unfolding plot(x, y=null,dimen=1, discrete=attr(x,"plot_discrete"), use.rownames=discrete, xlab=paste("dimension ",dimen),...) uapply(x,fun) Arguments x data ndims squared tol method y dimen type for unfold.matrix: a rectangular matrix that contains distances or squared distances (if argument squared is TRUE). For unfold.formula: a formula which specifies the variables that form the columns of the matrix of distances. For biplot.unfolding and plot.unfolding: an object that contains an unfolding solution. a data frame or an environment that contains variables specified in the formula given as first argument. an optional integer value that specifies the dimensionality of the solution. If NULL the dimensionality is selected automatically based on a singular value decomposition of the matrix of squared distances. a logical value; does the matrix D contain squared distances? a tolerance value for the convergence of the conjugate gradients method. a method for the iterative computation of the unfolding solution. a dummy argument for compatibility with default methods, ignored. for biplot: a two-element integer vector, for plot: a single integer value, that specifies the dimension(s) of the unfolding solution to be plotted. a character vector of length less then or equal to 2. Determines how each of the two point sets of the unfolding solutions are represented in the biplot. Valid choices are "points"the respective set of points are plotted as points in the biplot. "lines"the points of the respective set are connected by lines. "both"the points of the respective set are plotted as points and connected by lines. "text"the points of the respective set are represented by the corresponding row names and, if argument tpos is present, by points. "density"contour lines are drawn of two-dimensional kernel density estimate for the respective set of points. This biplot type uses the function kde2d of library MASS.

4 unfold tpos a two-element integer vector; specifies the position of text labels relative to the points. For the meaning of these integer values see text tposdim an integer value; specifies which how elements of tpos are used. Labels of points with negative positions along coordinate axis dimen[tposdim] are positioned according to tpos[1], labels of other points are positioned according to tpos[1]. xlab, ylab, xlim, ylim, asp, lty, lwd, pch, cex, col arguments passed to base graphics functions. contour.col, contour.lty colour and line type for contour lines, see contour. discrete use.rownames a logical vector of lenght 2; if TRUE, the respective set of points are represented by spikes in theplot, otherwise the set is represented by a graph of a kernel density estimate. logical; should row names used for annotation?... further arguments passed to optim in case of unfold or points in case of the plotting methods. FUN Details Value a function applied to the two sets of points that result from the unfolding. unfold first computes an unfolding solution according to Schoenemanns metric unfolding algorithm that uses only linear algebra operations. This preliminary solution is then refined by minimizing the stress using a conjugate-gradients method. uapply applies a given function to the two sets of points recovered by an unfolding solution. It applies the function to the components A and B of an object of class "unfolding". unfold returns an object of class "unfolding" with components A B fitted stress a numeric matrix representing the first set of points. Each row contains the coordinate of one point of the first set. a numeric matrix representing the second set of points. Each row contains the coordinate of one point of the second set. a numeric matrix that contains the fitted squared distances. A stress value, denotes the "badness of fit". Examples r <- seq(from=0,to=2*pi,length=24) a1 <- cos(r)*4 + 0.00001*rnorm(r) a2 <- sin(r)*4 + 0.00001*rnorm(r) b1 <- c(.5,-.5,-.5,.5)*3 + 5 b2 <- c(.5,.5,-.5,-.5)*3 + 1 D1 <- outer(b1,a1,"-") D2 <- outer(b2,a2,"-")

unfold 5 Dsq <- D1^2+D2^2 Dsq.uf<-unfold(sqrt(Dsq),squared=FALSE) oldpar <- par(mfrow=c(1,2)) A <- cbind(a1,a2) B <- cbind(b1,b2) ltype <- c(rep(1,nrow(a)),rep(2,nrow(a))) orig <- rbind(a,b) unfolded <- rbind(dsq.uf$a,dsq.uf$b) xlim <- ylim <- range(orig)#*1.5 plot(a,type="b",pch=1, xlim=xlim,ylim=ylim, xlab="dimension 1",ylab="Dimension 2",main=expression("Original data"),asp=1) lines(b,type="b",pch=3,lty=2) abline(h=0,v=0,lty=3) biplot(dsq.uf,type="b", xlim=xlim,ylim=ylim, main=expression(paste(italic(unfold)," solution")),asp=1) par(oldpar)

Index Topic hplot unfold, 2 Topic multivariate unfold, 2 biplot.unfolding (unfold), 2 contour, 4 kde2d, 3 optim, 4 plot.unfolding (unfold), 2 points, 4 procrustes, 2 text, 4 uapply (unfold), 2 unfold, 2 6