Questions tagged [ggally]

GGally is designed to be a helper to ggplot2. It contains templates for different plots to be combined into a plot matrix, a parallel coordinate plot function, as well as a function for making a network plot.

GGally is designed to be a helper to . It contains templates for different plots to be combined into a plot matrix, a parallel coordinate plot function, as well as a function for making a network plot.

Repositories

Resources

Vignettes

196 questions
0
votes
2 answers

Re-shaping data for plotting a network

I have a data set that I would like to re-shape for plotting as a network (following the work done here). The initial data frame looks like this: authors <- c('Author A', 'Author B', 'Author C', 'Author A', 'Author D', 'Author…
tlmoore
  • 125
  • 8
0
votes
1 answer

R GGally color edges by vertex membership

I am trying to create a list to color the edges of a graph depending on the grouping of the vertices they connect to. If an edge connects two members of the same group, the edge has their color. If the edge is between members of different groups,…
Jeff
  • 695
  • 1
  • 8
  • 19
0
votes
1 answer

GGally::ggpairs behaves differently for different variables when dealing with NAs

I have a dataset that I load with readr that has 2341 rows, 401 columns, and a few NAs peppered in. I'm trying to create scatterplot matrices with a subselection of continuous variables. Here's a glimpse of some of the variables I use: Observations:…
blahblahetcetc
  • 191
  • 1
  • 6
0
votes
1 answer

R: ggpairs throws 'names' attribute [2] must be the same length as the vector

I'm trying to put together a ggpairs visualization that uses the first column from a dataframe to specify the point colors, and columns 4-7 of the dataframe to create the point distributions: require(GGally) require(ggplot2) df <-…
duhaime
  • 25,611
  • 17
  • 169
  • 224
0
votes
1 answer

Changing the name of the terms in ggally::ggcoef

Given the following example iris_fat <- iris %>% mutate(is_fat = factor(ifelse(Sepal.Width * Petal.Width > 6 ,"fat", "not_fat"))) reg <- lm(Sepal.Length ~ Sepal.Width + Petal.Length + Petal.Width + is_fat, data = iris_fat) …
Alex
  • 2,603
  • 4
  • 40
  • 73
0
votes
1 answer

Binwidth error while using ggpairs

I am trying to generate a plot from my data set that gives the correlation between my variables. I am using the library GGally. here is my one line code. ggpairs(Imputed_data, title = "Scatterplot Matrix for the features of data Set") I am…
Mikz
  • 571
  • 2
  • 11
  • 29
0
votes
0 answers

Settings for column labels in ggpairs

I recently started working with ggplot2 and GGally and wanted to create a matrix of scatter plots for visualizing the correlation using the function ggpairs. The output looks quite nice using: ggpairs(df, axisLabels="none") All I want to change…
Bobipuegi
  • 521
  • 1
  • 4
  • 11
0
votes
0 answers

Error in .subset(col, i) : object of type 'symbol' is not subsettable

I am trying to assign colors to text in a ggpairs plot matrix depending on column correlations (high correlations are red, low ones are blue): colors <- colorRampPalette(c("blue", "red"))(100) correlation_color <- function(data, mapping, ...) { …
Gerry
  • 1,938
  • 3
  • 18
  • 25
0
votes
1 answer

Rounding digits in ggpairs

Is it possible to round the correlations digits in ggpairs to, for example 2 digits somehow? library(GGally) ggpairs(iris, columns = 1:4, mapping = ggplot2::aes(col = Species))
MLEN
  • 2,162
  • 2
  • 20
  • 36
0
votes
1 answer

Specify the colour of ggpairs plot using a variable but not plot that variable

I have a dataset from the world bank with some continuous and categorical variables. > head(nationsCombImputed) iso3c iso2c country year.x life_expect population birth_rate neonat_mortal_rate region 1 ABW AW …
TheGoat
  • 2,587
  • 3
  • 25
  • 58
0
votes
1 answer

Custom group mean function for ggpairs

As per the documentation of the ggpairs() function in the GGally R package, it is possible to specify custom functions as input to the "lower"/"upper" argument. For continuous-discrete variable combinations, I would like to simply display the means…
h_bauer
  • 33
  • 5
0
votes
1 answer

How to plot scatterplot of a variable in a dataframe with all other variables in a single plot using R?

I tried using ggpairs in GGally to plot scatterplots. But it plots each variable With all other variables. I want to plot scatterplot of a particular variable against all other variables in dataframe with correlation value of each scatterplot…
user6359857
0
votes
1 answer

how to regulate ggparis plot

I draw a plot using ggpairs (like below) but it looks very confusing. As to fix it, I have read the documentation but that did not help much. How can I reduce the font size of the coefficients? And second, I'm wondering how this plot can be…
Brian
  • 251
  • 4
  • 14
0
votes
1 answer

ggpairs displaying density functions as unfilled lines

I am hoping to just change the diagonal plots to have simple outlines so I can view the overlap of the density functions more clearly but am not having much luck. Here is the code I have been using: plot_rh <- ggpairs(data_rh[,1:6], mapping =…
0
votes
1 answer

Density and correlation values in ggPairs shifted to left in ggplotly()

I am using the package GGally (and method ggpairs) to create scatterplot matrices. I notice that the static version (object p below) appears to have correctly-centered correlation values and densities. The image below demonstrates this - However,…
user2808302