Questions tagged [grimport]

20 questions
7
votes
2 answers

Using an image as point icon in ggmap

I am trying to create a simple ggmap with a number of schools. I can easily get to the point where the schools show up as points on the map (code below). But, I would like to bring in an image of a school icon to use instead of the points. As far…
6
votes
1 answer

Windows R:grImport ghostscript error 'status 127'

I've installed Ghostscript and grImport in R (Windows, Rstudio). I'm following the tutorial but I immediately get the error, > library(grImport) Loading required package: grid Loading required package: XML > PostScriptTrace("petal.ps") Error in…
noname
  • 473
  • 4
  • 11
5
votes
2 answers

Use SVG images as symbols in gglot2

I would like to use vector graphics stored in external files (e.g. SVG) as my plotting symbols in a ggplot2 figure. e.g. following this example from the grImport vignette (Fig. 8) https://cran.r-project.org/web/packages/grImport/vignettes/import.pdf…
Mark Payne
  • 557
  • 5
  • 12
3
votes
1 answer

Alter color in Picture class in grImport

I found a terrific package grImport for reading in .ps files (vector vs. raster). It works very well and the reader can find the package info here: http://cran.r-project.org/web/packages/grImport/grImport.pdf and a demo…
Tyler Rinker
  • 108,132
  • 65
  • 322
  • 519
2
votes
0 answers

Insert figure in a multipanel plot using R

I need to insert 4 graphic pictures (.ps) into a multipanel (4 boxes) using R. Does anybody has a tip for it? I have search a lot and I didn't find a solution. The way I'm trying now (but no success) is using screen: m <- rbind(c(0.1, 0.55, 0.55,…
2
votes
0 answers

changing height of picture in grid.symbol function of grImport package

I'm following this example from the grImport package vignette page 15: R> xyplot(V8 ~ V7, data = flower, + xlab = "Height", ylab = "Distance Apart", + panel = function(x, y, ...) { + grid.symbols(PSflower, x, y, units = "native", + size = unit(5,…
Omar Wagih
  • 8,504
  • 7
  • 59
  • 75
1
vote
0 answers

Properly lay out external svg files in ggarrange

Long story short, I have a few svg images which I want to lay out using ggarrange (and ideally get into a ggplot to use ggtitle() and so on). I can import the images with rsvg and grImport, but the layout get's somehow messed…
1
vote
0 answers

Extract plotting region coordinates for grid.picture() in R

Background I am plotting the following image: Using this code: par(mfrow = c(2, 2), mar = c(2, 2, 2, 2)) plot(1, col = "red", pch = 15) plot(1, col = "blue", pch = 15) plot(1, col = "orange", pch = 15) plot(1, col = "purple", pch = 15) I'd…
Gimelist
  • 791
  • 1
  • 10
  • 25
1
vote
1 answer

Difference between ggplot and grid.picture with complex shapes

I wish to obtain the x/y coordinates of individual letters and plot them with ggplot. I am using grImport::PostScriptTrace to obtain an XML file from a Postscript file. From there I extract x, y coordinates from the S4 object of class…
ixodid
  • 2,180
  • 1
  • 19
  • 46
1
vote
0 answers

plotting svg via grImport2 works fine in terminal, not via knitr

The below chunk works fine inside the terminal, but ominously fails when run via knitr (or rather, rmarkdown). --- title: "test-svg" author: "foo" date: "8/12/2018" output: html_document --- # Title ```{r} # please download this file …
maxheld
  • 3,963
  • 2
  • 32
  • 51
1
vote
1 answer

How do I use a 'picture' object as a symbol in a graph key?

I'm creating a graph using xyplot() from lattice, and using the grImport package to plot a picture as a plotting symbols with grid.symbols(). This is a brief version of the code for my graph, where 'mypic' is the picture object (created with…
edstatsuser
  • 220
  • 2
  • 7
1
vote
2 answers

PostScriptTrace Error

I am trying to import a vector graphic of the brain into R using the GrImport function. When inserting the following function: PostScriptTrace("~/Dropbox/shared/Brain_mapping/Human-brain.ps", "~/Dropbox/shared/Brain_mapping/Human-brain.xml") I get…
0
votes
0 answers

Major issue grimport : scripts ids system broken

I had too many scripts, and I wanted to show only the most important ones. I copied the database table ps_megaimporter_concurrents to a replicate table, ps_megaimporter_concurrents_ex, and I deleted most of the scripts I didn't use, but I did it…
0
votes
1 answer

Get xy path coordinates of letters in a word

I wish to use gganimate and tweener to morph some letters into other letters. Thus, I need a dataframe of x, y coordinates for each letter in a word as input to ggplot. I'm not really sure how to do this, but my thinking is that library(grImport)…
ixodid
  • 2,180
  • 1
  • 19
  • 46
0
votes
1 answer

get too many request in ASP.NET MVC

I have a project with ASP.NET MVC at the end, I Installed Glimpse and get a log, the result log was stange. I have 24088 requests. How can I know where request call? I have just about 15 css and js files and about 5 action call. How can I decrease…
work question
  • 321
  • 2
  • 11
1
2