Questions tagged [hmisc]

Hmisc is an R package of miscellaneous utility functions.

Hmisc is an package of miscellaneous functions by Frank Harrell. It contains many functions useful for , ting, utility operations, functions for computing and power, importing datasets, imputing , advanced table making, , manipulation, conversion of R objects to code, and recoding variables.

Repositories

Other resources

Related tags

216 questions
1
vote
1 answer

R - how to limit output for hmisc rcorr?

I have two data frames motivation_on with 60 observations and motivation_off with 146 observations, each consists of 21 vars and 1 ID column, which is in the first column. Now I want to know how the vars correlate with each other so I…
florian
  • 604
  • 8
  • 31
1
vote
1 answer

Extracting complete dataframe from Hmisc package in R

I've used aregImpute to impute the missing values then i used impute.transcan function trying to get complete dataset using the following code. impute_arg <- aregImpute(~ age + job + marital + education + default + balance + housing + loan + contact…
1
vote
0 answers

Hmisc and LaTeX multicloumn

I am trying to create a multicolumn in a LaTeX table. It's easy to do this manually but I create these tabled from data frames generated fro many reports so doing it manually is time consuming. What I have is : cat(cfrm, file="table2.tex") # this…
SteveB
  • 11
  • 1
1
vote
2 answers

Latex math mode in Hmisc variable labels using compareGroups table

I want to produce a number of tables for the same set of variables. I use the wonderful R package compareGroups and Hmisc to assign variable labels so that I don't have to change variable names for each table. Some variable names include latex math…
ehi
  • 409
  • 8
  • 23
1
vote
1 answer

Hmisc labels in complex plots (SPLOM)

Is there an easy way how Hmisc labels that have been defined earlier appear in a complex R plot e.g. a SPLOM (scatter plot matrix)? # defining labels library(Hmisc) label(mtcars$mpg) <- "Miles per gallon" label(mtcars$qsec) <- "quarter mile time" #…
ehi
  • 409
  • 8
  • 23
1
vote
1 answer

plot monthly data with xyplot with R

I want to plot this data frame with month on x-axis. month value1 value2 value3 value4 1 Okt 19.5505 19.6145 19.5925 19.3710 2 Nov 21.8750 21.7815 21.7995 20.5445 3 Dez 25.4335 25.2230 25.2800 22.7500 t = read.csv("Mappe1.csv", header =…
N_ni
  • 27
  • 4
1
vote
0 answers

Hmisc::latex function not working correctly when using both cellTexCmds and cgroup arguments (newer R/package version)

I'm trying to format a table for LaTeX using the latex function in the Hmisc package, using both the cellTexCmds argument to format specific cells, and the cgroup/n.cgroup arguments to produce header groupings. The behaviour I'm expecting happens in…
aPaulT
  • 593
  • 3
  • 8
1
vote
1 answer

Using cut2 in Hmisc package for large N

It seems that for large N (say 2e6) the cut2 function in the Hmisc package throws an error y = cut2(rnorm(2000000,0,1),m=sqrt(2000000)) Error in if (cj == upper) next : missing value where TRUE/FALSE needed In addition: Warning message: In…
stats134711
  • 624
  • 1
  • 5
  • 15
1
vote
0 answers

"rcorr" function and multiple testing correction

Do p values produced by rcorr have to be corrected for multiple comparison or does this function account for multiple testing? In the output of p-values table I have correlations significant at different levels (e.g. .05, .001) and I don't seem to…
1
vote
1 answer

R - cut2 versus quantile function

Could anyone please tell me the difference between the quantile function in R and the cut2 function from the HMISC package? I understand that the quantile has 9 different methods for specifying quartiles. However, when I use the function…
Maeve90
  • 345
  • 1
  • 6
  • 14
1
vote
1 answer

Error installing Hmisc in R 3.3.0 on centos 6.7

I have installed R 3.3.0 on a centos 5.2 server, and am trying to install the packages I need to run a shiny app; one of the packages is Hmisc and causing an error. Unfortunately, I have no idea how to proceed. Could someone advise please? Do I need…
1
vote
2 answers

Suppressing axis labels in R Hmisc errbar

I want to produce a horizontal dotchart with error bars, with a log x axis. I've explored a few options and got the closest to what I want with errbar from the package Hmisc. But I don't want to label the y-axis for each data point. I've tried…
Jenni G
  • 35
  • 1
  • 4
1
vote
0 answers

download getRs function from Hmisc

I have the latest version of R,Rstudio, Hmisc- which should has getRs function..same error with knitrSet function. require(Hmisc) getRs() Error: could not find function "getRs" knitrSet('reg', width=80) Error: could not find function…
1
vote
0 answers

Error while using Hmisc package : (list) object cannot be coerced to type 'double'

I want to find pearson correlation. #cols is 100 and #rows is 300. I am using the following commands: library(Hmisc) x <- (read.csv("input.csv",header=TRUE)) y <- rcorr(as.matrix(as.numeric(x)), type="pearson") Error in as.matrix(as.numeric(x)) :…
Akriti
  • 21
  • 1
  • 4
1
vote
1 answer

Speeding up a function used to create convenient groups for mapping and charting

Background Following useful discussions, and help that I received from the SO colleagues with respect to: the efficient use of the cut2 function in the Hmisc package, ordering messy string vectors, creating pretty breaks and handling formatting I…
Konrad
  • 17,740
  • 16
  • 106
  • 167