On Wed, Jan 18, 2012 at 1:36 AM, Henrik Bengtsson
<henrik.bengts...@aroma-project.org> wrote:
> Hi,
>
> the loading of the Cairo package is misleading here, since it is
> actually not utilizing it.  (In the next version of aroma.core, the
> Cairo package will not be loaded unless really needed).  Instead,
>
>>> print(pngDev)
>> function (...)
>> pngTyped(..., type = "cairo")
>> <environment: 0x103f64b88>
>
> tells me that it here in the end uses png(..., type="cairo"), because
> internally pngTyped <- function(...) png(...);  To confirm, start a
> fresh R session and check if the following gives you an empty PNG
> file?
>
> png("foo.png", type="cairo"); plot(1:10); dev.off();
>
> If so, what about type="cairo-png"?   Your reply will help me update
> findPngDevice() such that it will find a working PNG device (these
> problems are indeed why it was created in the first place; it is hard
> to find a cross-platform working driver).

So, if it turn out you really have problems with your built in
png(..., type="cairo") device, before trying fix it/rebuild R, could
you please verify that the updated R.utils 1.9.11 and aroma.core 2.4.3
manage to detect the problem and find another working device for you?
As usual, update via:

source("http://aroma-project.org/hbLite.R";);
hbLite("aroma.affymetrix");

and then retry:

library("aroma.core");
pngDev <- findPngDevice(transparent=FALSE);
pngDev("foo.png"); plot(1:10); dev.off();

Does it work?  It could be that when you do the above you get the
warning, then it more or less halts for 10secs (while waiting to see
if that zero file grows; this delay occurs only once per R session),
before it returns a working PNG device.

/Henrik

>
> /Henrik
>
> On Tue, Jan 17, 2012 at 9:09 PM, Steven McKinney <smckin...@bccrc.ca> wrote:
>> Hi Henrik
>>
>> If I just load the Cairo library and do a PNG plot, the plot appears
>> in the png file alright (8 kb file).  I also don't notice the message
>> about "libpng warning: Application built with libpng-1.2.41 but running with 
>> 1.5.7"
>>
>> So there appears to be something amiss in aroma.affymetrix
>> in its interface to Cairo devices.  Does this provide any clues?
>> I have not gone through the aroma source to understand
>> how aroma interacts with Cairo.
>>
>> Steve
>>
>> R version 2.14.1 (2011-12-22)
>> Copyright (C) 2011 The R Foundation for Statistical Computing
>> ISBN 3-900051-07-0
>> Platform: x86_64-apple-darwin10.8.0/x86_64 (64-bit)
>>
>> R is free software and comes with ABSOLUTELY NO WARRANTY.
>> You are welcome to redistribute it under certain conditions.
>> Type 'license()' or 'licence()' for distribution details.
>>
>>  Natural language support but running in an English locale
>>
>> R is a collaborative project with many contributors.
>> Type 'contributors()' for more information and
>> 'citation()' on how to cite R or R packages in publications.
>>
>> Type 'demo()' for some demos, 'help()' for on-line help, or
>> 'help.start()' for an HTML browser interface to help.
>> Type 'q()' to quit R.
>>
>>> .help.ESS <- help
>>> options(STERM='iESS', editor='emacsclient')
>>> require("Cairo")
>> Loading required package: Cairo
>>> CairoPNG("foo.png", width=840, height=640); plot(1:10); dev.off();
>> null device
>>          1
>>>
>>
>>
>>
>>
>> Steven McKinney
>>
>> ________________________________________
>> From: Steven McKinney
>> Sent: January 17, 2012 8:59 PM
>> To: aroma-affymetrix@googlegroups.com
>> Subject: RE: [aroma.affymetrix] ChromosomeExplorer producing zero byte png 
>> files
>>
>> Hi Henrik,
>>
>> Running the commands you provided, I get an empty foo.png.
>>
>>> print(pngDev)
>> function (...)
>> pngTyped(..., type = "cairo")
>> <environment: 0x103f64b88>
>>>
>>
>> Full output below.
>>
>> This is looking like a Cairo problem.
>>
>>
>> R version 2.14.1 (2011-12-22)
>> Copyright (C) 2011 The R Foundation for Statistical Computing
>> ISBN 3-900051-07-0
>> Platform: x86_64-apple-darwin10.8.0/x86_64 (64-bit)
>>
>> R is free software and comes with ABSOLUTELY NO WARRANTY.
>> You are welcome to redistribute it under certain conditions.
>> Type 'license()' or 'licence()' for distribution details.
>>
>>  Natural language support but running in an English locale
>>
>> R is a collaborative project with many contributors.
>> Type 'contributors()' for more information and
>> 'citation()' on how to cite R or R packages in publications.
>>
>> Type 'demo()' for some demos, 'help()' for on-line help, or
>> 'help.start()' for an HTML browser interface to help.
>> Type 'q()' to quit R.
>>
>>> .help.ESS <- help
>>> options(STERM='iESS', editor='emacsclient')
>>> library("aroma.core")
>> Loading required package: R.methodsS3
>> R.methodsS3 v1.2.1 (2010-09-18) successfully loaded. See ?R.methodsS3 for 
>> help.
>> Loading required package: R.oo
>> R.oo v1.8.3 (2011-11-01) successfully loaded. See ?R.oo for help.
>>
>> Attaching package: ‘R.oo’
>>
>> The following object(s) are masked from ‘package:R.methodsS3’:
>>
>>    throw.default
>>
>> The following object(s) are masked from ‘package:methods’:
>>
>>    getClass, getClasses, getMethods
>>
>> The following object(s) are masked from ‘package:base’:
>>
>>    attach, detach, environment, gc, load, save
>>
>> Loading required package: R.utils
>> R.utils v1.9.9 (2012-01-11) successfully loaded. See ?R.utils for help.
>>
>> Attaching package: ‘R.utils’
>>
>> The following object(s) are masked from ‘package:utils’:
>>
>>    timestamp
>>
>> The following object(s) are masked from ‘package:base’:
>>
>>    cat, commandArgs, getOption, inherits, isOpen, lapply, parse,
>>    remove, warnings
>>
>> Loading required package: R.cache
>> R.cache v0.5.2 (2011-10-05) successfully loaded. See ?R.cache for help.
>>
>> Loading required package: R.filesets
>> Loading required package: digest
>> R.filesets v1.1.4 (2011-11-19) successfully loaded. See ?R.filesets for help.
>>
>> Attaching package: ‘R.filesets’
>>
>> The following object(s) are masked from ‘package:R.cache’:
>>
>>    getChecksum
>>
>> The following object(s) are masked from ‘package:base’:
>>
>>    append, readLines, sapply
>>
>> Loading required package: R.rsp
>> R.rsp v0.7.1 (2011-11-28) successfully loaded. See ?R.rsp for help.
>>  Type browseRsp() to open the RSP main menu in your browser.
>>
>> Attaching package: ‘R.rsp’
>>
>> The following object(s) are masked from ‘package:R.filesets’:
>>
>>    getHeader
>>
>> The following object(s) are masked from ‘package:base’:
>>
>>    flush, restart, stop, write
>>
>> Loading required package: matrixStats
>> matrixStats v0.4.3 (2011-12-11) successfully loaded. See ?matrixStats for 
>> help.
>> Loading required package: aroma.light
>> aroma.light v1.22.0 (2011-10-31) successfully loaded. See ?aroma.light for 
>> help.
>> aroma.core v2.4.2 (2012-01-14) successfully loaded. See ?aroma.core for help.
>>
>> Attaching package: ‘aroma.core’
>>
>> The following object(s) are masked from ‘package:base’:
>>
>>    .Machine, append, apply, colMeans, colSums, library, require,
>>    sapply
>>
>>> pngDev <- findPngDevice(transparent=FALSE)
>> Loading required package: Cairo
>> libpng warning: Application built with libpng-1.2.41 but running with 1.5.7
>>> pngDev("foo.png", width=840, height=640); plot(1:10); dev.off();
>> libpng warning: Application built with libpng-1.2.41 but running with 1.5.7
>> null device
>>          1
>>> print(pngDev)
>> function (...)
>> pngTyped(..., type = "cairo")
>> <environment: 0x103f64b88>
>>>
>>> sessionInfo()
>> R version 2.14.1 (2011-12-22)
>> Platform: x86_64-apple-darwin10.8.0/x86_64 (64-bit)
>>
>> locale:
>> [1] en_CA/en_CA/en_CA/C/en_CA/en_CA
>>
>> attached base packages:
>> [1] stats     graphics  grDevices utils     datasets  methods   base
>>
>> other attached packages:
>>  [1] Cairo_1.5-1        aroma.core_2.4.2   aroma.light_1.22.0 
>> matrixStats_0.4.3
>>  [5] R.rsp_0.7.1        R.filesets_1.1.4   digest_0.5.1       R.cache_0.5.2
>>  [9] R.utils_1.9.9      R.oo_1.8.3         R.methodsS3_1.2.1
>>>
>>
>> --
>> When reporting problems on aroma.affymetrix, make sure 1) to run the latest 
>> version of the package, 2) to report the output of sessionInfo() and 
>> traceback(), and 3) to post a complete code example.
>>
>>
>> You received this message because you are subscribed to the Google Groups 
>> "aroma.affymetrix" group with website http://www.aroma-project.org/.
>> To post to this group, send email to aroma-affymetrix@googlegroups.com
>> To unsubscribe and other options, go to http://www.aroma-project.org/forum/

-- 
When reporting problems on aroma.affymetrix, make sure 1) to run the latest 
version of the package, 2) to report the output of sessionInfo() and 
traceback(), and 3) to post a complete code example.


You received this message because you are subscribed to the Google Groups 
"aroma.affymetrix" group with website http://www.aroma-project.org/.
To post to this group, send email to aroma-affymetrix@googlegroups.com
To unsubscribe and other options, go to http://www.aroma-project.org/forum/

Reply via email to