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 8772633
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T18:05:01+00:00 2026-06-13T18:05:01+00:00

After struggling with some maps I came to the point where I don’t know

  • 0

After struggling with some maps I came to the point where I don’t know any further. I want to add pie charts to a geographical map.

Here is my data:

    zip city      state  latitude   longitude   plan_chosen
  10001 New York    NY  40.75074    -73.99653   3
  10001 New York    NY  40.75074    -73.99653   1
  10001 New York    NY  40.75074    -73.99653   1
  10017 New York    NY  40.75216    -73.97231   3

This is also for other locations.What I want to do is define a pie chart of plan_chosen. This consists of numbers 1 to 4, and I want to put this pie chart on the map of the states of course in the NY area and some other selected areas.
I couldn’t really find a tutorial on how to do this and I don’t know which package to use best. Just for mapping I’ve been using the package maps

I use this code to define the map

map('state', fill=FALSE, col="#cccccc")

on this I want to add 3 to 4 pie charts. Do I have to modify the data any further or which package is useful?

I’ve been trying the package rworldmap and this code

mapPies( tel,nameX="longitude", nameY="latitude" , nameZs=plan_chosen,mapRegion='america' , add=TRUE)

but here my problem is it doesn’t divide the pie in 4 parts it just colors it all black. Any suggestions or help?

  • 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-13T18:05:02+00:00Added an answer on June 13, 2026 at 6:05 pm

    There is a function in the plotrix package that will create floating pie charts. But note that the author of the function does not encourage their use, he wrote it to show that R can descend to making plots that are as useless as excel in hopes that users would then be converted to better ways of presenting their data.

    You can also use the subplot function in the TeachingDemos package to add any type of chart to an existing plot (map), so it could be used with pie charts, or other more useful charts. Also look at the my.symbols function in the same package for other ways to add information to an existing plot/map.

    Others have mentioned Edward Tufte (excelent suggestions), but also look for William Cleveland for studies on the effectiveness (or lack there of) of different types of plots.

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

Sidebar

Related Questions

I'm struggling with trying to modify some Javascript code. I know what I want
After some struggling I managed to get boost smart pointers to build for Windows
I'm trying (or rather struggling) to create a little Blackjack game. After some JavaScript
I am using Xcode and, after some struggling, it is compiling my dynamic libraries
i am really struggling to load some numeric floating point data from a file
I'm trying to add some rich snippets to my site and am struggling a
I'm refactoring some older SQL, which is struggling after 4 years and 1.7m rows
I've got gettext setup within PHP5. After some struggling with the charactersets and the
OK so after struggling for a while trying to get cURL to fetch a
After a week of struggling I just got the msdeploy handler up on IIS7

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.