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

  • Home
  • SEARCH
  • 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 4016024
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T09:41:24+00:00 2026-05-20T09:41:24+00:00

Full disclosure: this issue is duplicated on the ggplot2 google group I’m developing a

  • 0

Full disclosure: this issue is duplicated on the ggplot2 google group

I’m developing a package that makes heavy use of ggplot2. I’ve created my own geom—geom_rug_alt—as a way of putting rug fringes on the top/right of the plot instead of the default locations.

My problem is that when geom_rug_alt() is defined and called within a single script, it seems to plot just fine. (Please try it yourself to verify that.) But, in my package geom_rug_alt() is defined in one file (CommonFunctions.R) and called in another (the Residuals() function of larger function foo.R). When I call foo.R on something, I get this error:

Error in geom_rug_alt(aes(x = NULL, y = within.group.residuals, color = factor(within.1.sd.of.the.mean.of.all.residuals)),  : 
object 'GeomRugAlt' not found

Now, I’ve done a couple of things (suggested by Hadley in this thread) to try to make sure that geom_rug_alt() should work properly within the package:

  1. I define GeomRugAlt as a proto object in a file essentially called CommonFunctions.R within my package. CommonFunctions.R contains lines 3-42 of my example script.

  2. In CommonFunctions.R, I was sure to include the build_accessor() line for geom_rug_alt (line 42 in my example script) after the definition of GeomRugAlt

  3. In the package DESCRIPTION file, I have a collate: line where CommonFunctions.R appears first

  4. In the package DESCRIPTION file, I have a LazyLoad: false line
  5. In CommonFunctions.R, I included a require(ggplot2) call before defining GeomRugAlt as a proto object.
  6. In foo.R, I included a require(ggplot2) call before calling geom_rug_alt() within Residuals().

I’m not sure what else I’m missing. Given that my example script runs just fine, I suspect the issue isn’t that my geom doesn’t work, but that I’m doing something wrong as part of the package development process.

Sorry for duplicating the issue, but I can’t seem to find a thorough solution to the problem 🙁

  • 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-05-20T09:41:24+00:00Added an answer on May 20, 2026 at 9:41 am

    Put export(GeomRugAlt) in the NAMESPACE file.

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

Sidebar

Related Questions

How would you define testing? In the interest of full disclosure, I'm posting this
Full disclosure : This is for a homework assignment. This is driving me nuts.
First off, full disclosure: This is going towards a uni assignment, so I don't
Full disclosure, this is part of a homework assignment (though a small snippet, the
full disclosure - this is for a homework assignment. And I normally would not
Full Disclosure: I am bad at javascript. I'm trying to write something that takes
Full disclosure: this is for a school project. The project is in C++. They
Full disclaimer: I'm a CS student, and this question is related to a recently
In the Full .NET framework you can use the Color.FromArgb() method to create a
Full disclosure, I'm new to Visual Studio Web Tests and coding for them. I've

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.