32 questions
0
votes
1
answer
72
views
How to shift the labels from right to left? [duplicate]
I'm using ggplot2 in R to create a dotplot where the x-axis is the variable name and the y-axis is the cell line ID. The plot is faceted by a Group variable ("Foci formation", "Soft ...
2
votes
1
answer
93
views
How can I decrease the space between my points on y-axis in geom_dotplot in R?
I'm trying to make a dotplot with antibody titers (y-axis) ranging from 1:20 to 1:640 by site (x-axis) and I can't reduce the space between the points on the y-axis.
I tried applying log2 to the scale,...
0
votes
1
answer
65
views
is there a way to only display dots for individual data points on a boxplot if they are above/below a certain range?
I would like to create a boxplot for my data where the boxplot itself represents the IQR and the whiskers represent the 5th to 95th percentile values. I want to use geom_dotplot to only show the ...
0
votes
1
answer
37
views
Variable legend outlined in appropriate color, but filled with black dot
I have used ggplot in R to generate a dot plot with three "samples" (Adipocytes, BAT and WAT) which are colored by ""group". The plot is correct, but the "group" ...
0
votes
0
answers
115
views
Adding a regression line to a dotplot, or stacking overlapping points horizontally without dotplot
I'm trying to create a graph which shows the regression line and of this data and meaningfully shows the individual points. If I keep the x axis data as numeric and use a scatter plot, the graph looks ...
0
votes
2
answers
102
views
How do I split and modify the dotplot of a multiple mixed effects model in R
I have the following script in R 4.3.1, this isnt the complete script but just the relevant parts:
library(lme4)
library(lmerTest)
library(ggplot2)
library(lattice)
library(RColorBrewer)
MEDE.fin <...
0
votes
1
answer
64
views
make a dotplot of differences in variables
I cant figure out how to plot the difference between two variables, female and male, I want to make a dotplot of female - male.
my attempts so far are:
MyData$earn_diff <- MyData$female - MyData$...
1
vote
1
answer
59
views
dodging dots with geom_dotplot() if number of dots exceeds n for an x value
This is my dataframe:
DF <- structure(list(pub_year = c(2022, 2023, 2022, 2022, 2021, 2023, 2019,
2022, 2022, 2022, 2022, 2023, 2019, 2020,
...
0
votes
1
answer
93
views
how to show SE along with dots in a dot plot in Stata
I want to make a dot plot with showing mean and SE in the plot in Srara. But, I am not able to make the SEs in graph. Anyone has any example code to do that? I have a continuous value in the y-axis ...
0
votes
0
answers
836
views
Warning: Scaling data with a low number of groups may produce misleading results
When I reduce the number of identity in DotPlot the script return the following warning: "Warning: Scaling data with a low number of groups may produce misleading results"
I use this command:...
0
votes
0
answers
194
views
Decrease font size of y axis on R software code
I am using the following code for dot plot.I have to write name of Indian states in y axis. but I am unable to control the font size.
dotchart(data, xlim = c(0, 1), pch = 20, col=c("darkblue"...
0
votes
0
answers
827
views
Dotplot of enrichGO results with All of the Ontology terms on same plot for comparison arranged on the basis of the category
I want to create such a dotplot with dotplot of clusterprofiler. Here you can see that the Ontology terms are arranged on same plot with labels at the left of the plot. I was wondering if this can be ...
1
vote
1
answer
167
views
Frequency plot using dots instead of bars?
I'm trying to create the chart in this question, using this answer. I'm open to any solution that works.
Visual borrowed from original question:
Difference from that question is I've already ...
0
votes
1
answer
148
views
How can I make a 4-column scatter/dot plot on R?
I want to make a scatter/dot plot with four different groups of data. My groups are MA-H2o, MA-Cu, OA-H2o, and OA-Cu.
I found a previous answer here and made each group into its own separate data set/...
0
votes
2
answers
265
views
How to reorder a dot plot in R
I have this dataset on the percentage of individuals who own a car in five different cities between 1992 and 1999:
city <- c("A", "A", "B", "B", "F"...
1
vote
1
answer
138
views
How can I make stacked dot plots using a facet in GGplot2? R
I am trying to stack dot plots using a facet in GGplot2.
My first dot plot:
plot1 <- ggplot(marathon, aes(x = MarathonTime, y = first_split_percent)) +
geom_point()
plot1
My second:
plot2 <- ...
0
votes
2
answers
78
views
Automatic break after n-dots in geom_dotplot-function in ggplot in R
I have got a problem in managing multiple observations in the geom_dotplot-function due to overlap between different groups:
v1 <- c(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,...
1
vote
1
answer
244
views
How can I add a year slider to this Ranged Dot Plot in Vega Lite?
I have a dataset with relevant values from 2000-2019, and when I load up the graph with this specification:
"data": {
"name": "chart6",
"url": "...
0
votes
1
answer
137
views
Change ylims on dotplot with ggplot
I want to build a dot plot with y limits from -3 to 3. This one time, my data does not contain -3, so it does not show up on my plot. I was not abe to manually change ylim to (-3,3). Is there a way to ...
1
vote
0
answers
179
views
R: Make a box plot using different shapes for data points with no overlapping data points using geom_dotplot()
I have a dataset that looks like this. It's saved as a file called "prescriptivism_scores.csv":
Usage_Guide
Usage_Problem
Prescriptivism_Index
Book 1
who/whom
2
Book 2
who/whom
2
Book 3
who/...
1
vote
1
answer
290
views
How change color after certain intervals in ggplot2?
I have following data:
dput(data)
I used following code to generate the plot:
p <- ggplot(data, aes(Zscore, ID))
p + geom_point(aes(colour=pval, size=Hit)) +
scale_color_gradientn(colours=...
0
votes
0
answers
281
views
Adding labels to end of line in ggplot2 in R
I am producing a lollipop graph in ggplot2 in R using dot_plot. However I would like to add one label to the end of each line to indicate each line represents 1 SNP. I would like the label to be at ...
1
vote
1
answer
460
views
Ggplot2 using same value for all X values on graph
CODE:
Lef4 <- read.csv2("Lef4 expression.csv")
head(Lef4_expression)
Lef4graph <- ggplot(Lef4_expression,aes(x = Hour, y = Copies.Lef4.ng)) +
geom_dotplot(binaxis = 'y', stackdir =...
0
votes
1
answer
571
views
How can I add a mean bar and a jitter to my dot plots?
I am trying to compare data from three groups and I would like to have a mean bar on every group and some jitter.
first <- c(1, 1.2, 2, 3, 4)
second <- c(5, 6, 7, 8, 9)
third <- c(10, 16, 17, ...
1
vote
0
answers
122
views
Animated dotplot (using gganimate in R)
I have a data frame of countries and some events in each country. How to animate a dotplot of events for each country through time
df <- data.frame(country = factor(c("Mexico", "USA&...
0
votes
1
answer
94
views
How to make a dotplot with a discontinuous axis in R
Hi I'm trying to make a dotplot but have got pretty big differences between my groups so am trying to create a graph with breaks in the axis to display this:
Condition
Value
A
0
A
0
A
0
B
650
B
1600
B
...
1
vote
2
answers
251
views
ggplotly hover text doesn't work with geom_dotplot
I would like to add hover text annotations to a dot plot in R. But ggplotly doesn't seem to work with geom_dotplot.
I would like the final dotplot to look like something this:
df <- data.frame(...
0
votes
1
answer
104
views
Columns into Rows for data
I am trying to add the gene names onto a heat map.
To do this I have had to use Biomart to match the Gene names to the Ensembl ID's.
Then I wanted to bring the gene names to be the row names on the ...
1
vote
0
answers
345
views
Is there a way in R to draw grouped dotplots without converting the data from wide to long format?
I am using an r data frame which looks something like:
df = data_frame(
A=c(sample(0:2,size=50,replace=TRUE)),
A1=c(sample(0:50,size=50,replace=TRUE)),
A2=c(sample(0:50,size=50,replace=TRUE)))
I am ...
0
votes
1
answer
260
views
How can I rearrange the order of y-axis on cleveland dot plot?
I have a Table and I generated a
Hallmark Cleveland plot to visualize the enrichment scores before and after applying my software. But how can I rearrange the order of my plot to look like this ? I ...
3
votes
1
answer
8k
views
How to plot a dot plot type scatterplot in matplotlib or seaborn?
Let's say I have a df like this:
df = pd.DataFrame({'col1': list('aabbb'), 'col2': [1, 3, 1, 5, 3]})
col1 col2
0 a 1
1 a 3
2 b 1
3 b 5
4 b 3
I would like to see ...
2
votes
0
answers
835
views
Cleveland's dotplot using Python ggplot
I am very new to ggplot. I am trying to create a dotplot in this fashion.
https://stackoverflow.com/a/20621581/229075
I don't have much luck so far. My trial below
df=DataFrame({'label':['a', 'b', 'c']...