Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8918677
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T05:48:53+00:00 2026-06-15T05:48:53+00:00

I got a simple data.frame (AD0) with basic statistical values and the factor(group): mean

  • 0

I got a simple data.frame (AD0) with basic statistical values and the factor(group):

       mean         se        sd median group
value1 0.725 0.07149951 0.4522026      1     1
value2 0.650 0.07637626 0.4830459      1     2
value3 0.175 0.06084343 0.3848076      0     3
value4 0.375 0.07752171 0.4902903      0     4

I tried to make a simple barplot with:

p <- ggplot(AD0, aes(mean,group)) + geom_bar()

However, I get the message: “Error: No layers in plot”
It is such a simple thing and I can’t get my head around why its not working.

I would be really glad if somebody could help me

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T05:48:54+00:00Added an answer on June 15, 2026 at 5:48 am

    Since you have presummarised data, you need to specify stat = "identity" in geom_bar.

    library(ggplot2)
    ggplot(AD0, aes(group, mean)) + geom_bar(stat = "identity")
    

    Furthermore, I suppose you want to use group for the x-axis and mean for the y-axis. I switched the order of both names.

    enter image description here

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got this simple Perl script: #! /usr/bin/perl -w use strict; use Data::Dumper; my
I've got a data frame with far too many rows to be able to
I've got simple JavaBeans objects which represents data in my database. I want to
I've got this simple piece of code: char data[4] = { 0x13, 0x34, 0xad,
This has got to be a simple answer. I want to subset my data
I've got a simple function to get some additional data based on request.user: def
Got a simple form, posting to an action... the action takes the data and
Ok, I've got a list like this (just a sample of data): data =
I just found Data::Section and I got interested in it. Unfortunately, I simply cannot
got a simple web site, in html. I do a simple function to move

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.