[R] Extracting Width and Length of Each Shape in EPS File

Jeff Newmiller jdnewmil at dcn.davis.CA.us
Fri Apr 18 19:22:48 CEST 2014


How are we supposed to know what you are capable of? Regardless of the answer to that, I strongly suspect that you would not find that the effort required would yield a result worth your effort. R is really an interpreted language, so your ".exe" would just be calling the R interpreter for you... none of the configuration details of getting R installed would go away. You would also probably activate some GPL responsibilities if you were to share that ".exe" with anyone.
---------------------------------------------------------------------------
Jeff Newmiller                        The     .....       .....  Go Live...
DCN:<jdnewmil at dcn.davis.ca.us>        Basics: ##.#.       ##.#.  Live Go...
                                      Live:   OO#.. Dead: OO#..  Playing
Research Engineer (Solar/Batteries            O.O#.       #.O#.  with
/Software/Embedded Controllers)               .OO#.       .OO#.  rocks...1k
--------------------------------------------------------------------------- 
Sent from my phone. Please excuse my brevity.

On April 18, 2014 6:49:45 AM PDT, Muhammad Abdur Rehman Khawaja <kh.m.a.rehman at gmail.com> wrote:
>Can I convert above code into .exe?
>
>
>On Fri, Apr 18, 2014 at 4:53 PM, Muhammad Abdur Rehman Khawaja <
>kh.m.a.rehman at gmail.com> wrote:
>
>> Thank you very much
>>
>>
>>
>>
>>
>> On Thu, Apr 17, 2014 at 4:31 AM, Paul Murrell
><paul at stat.auckland.ac.nz>wrote:
>>
>>> Hi
>>>
>>> Here is a demonstration that might give you some ideas ...
>>>
>>> library(grImport)
>>> PostScriptTrace("flower.ps", "flower.xml")
>>> flower <- readPicture("flower.xml")
>>>
>>> grid.newpage()
>>> grid.picture(flower)
>>>
>>> # Extract each path, then look at the 'summary' for the path
>>> for (i in 1:flower at summary@numPaths) {
>>>   bb <- flower[i]@summary
>>>   # Draw the result as a check
>>>   grid.polygon(c(bb at xscale[1], bb at xscale[2],
>>>                  bb at xscale[2], bb at xscale[1]),
>>>                c(bb at yscale[1], bb at yscale[1],
>>>                  bb at yscale[2], bb at yscale[2]),
>>>                default.units="native",
>>>                gp=gpar(col=NA, fill=adjustcolor(i, alpha=.5)),
>>>                vp="picture.shape::picture.scale")
>>> }
>>>
>>> The flower.ps file in that example is available here ...
>>>
>>> https://www.stat.auckland.ac.nz/~paul/R/grImport/importFiles.tar.gz
>>>
>>> Hope that helps.
>>>
>>> Paul
>>>
>>>
>>> On 04/17/14 10:56, Jeff Newmiller wrote:
>>>
>>>> Have you read the vignettes that accompany that package?
>>>>
>>>> You should also read the Posting Guide for this mailing list, as
>HTML
>>>> email is not in general a good idea on this list.
>>>> ------------------------------------------------------------
>>>> ---------------
>>>> Jeff Newmiller                        The     .....       .....  Go
>>>> Live...
>>>> DCN:<jdnewmil at dcn.davis.ca.us>        Basics: ##.#.       ##.#. 
>Live
>>>> Go...
>>>>                                        Live:   OO#.. Dead: OO#.. 
>Playing
>>>> Research Engineer (Solar/Batteries            O.O#.       #.O#. 
>with
>>>> /Software/Embedded Controllers)               .OO#.       .OO#.
>>>>  rocks...1k
>>>> ------------------------------------------------------------
>>>> ---------------
>>>> Sent from my phone. Please excuse my brevity.
>>>>
>>>> On April 16, 2014 6:35:55 AM PDT, Muhammad Abdur Rehman Khawaja <
>>>> kh.m.a.rehman at gmail.com> wrote:
>>>>
>>>>> Respected Fellows,
>>>>> I need little bit guidance regarding, how Can I
>>>>> Extract/Calculate/Measure
>>>>> width and length of each every shape in .eps file. EPS file is
>being
>>>>> generated from Adobe Illustrator.
>>>>> I have used grImport Library in R language to import eps file in R
>>>>> environment, but I couldn't understand in which format the data is
>in
>>>>> and
>>>>> How can I manipulate it.
>>>>> I'll shall be thankful for your cooperation
>>>>> ------
>>>>> Kind Regards
>>>>> Khawaja Muhammad Abdur Rehman
>>>>> Mechatronics Engineer NUST
>>>>> Professional Profile:
>>>>> http://pk.linkedin.com/in/khawajamechatronicscaps/<kh.m.
>>>>> a.rehman at gmail.com>
>>>>>
>>>>>         [[alternative HTML version deleted]]
>>>>>
>>>>> ______________________________________________
>>>>> R-help at r-project.org mailing list
>>>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>>>> PLEASE do read the posting guide
>>>>> http://www.R-project.org/posting-guide.html
>>>>> and provide commented, minimal, self-contained, reproducible code.
>>>>>
>>>>
>>>> ______________________________________________
>>>> R-help at r-project.org mailing list
>>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>>> PLEASE do read the posting guide http://www.R-project.org/
>>>> posting-guide.html
>>>> and provide commented, minimal, self-contained, reproducible code.
>>>>
>>>>
>>> --
>>> Dr Paul Murrell
>>> Department of Statistics
>>> The University of Auckland
>>> Private Bag 92019
>>> Auckland
>>> New Zealand
>>> 64 9 3737599 x85392
>>> paul at stat.auckland.ac.nz
>>> http://www.stat.auckland.ac.nz/~paul/
>>>
>>
>>




More information about the R-help mailing list