Dear both,

   It turned out that the problem is caused by the "eset" parameter: it
must be an ExpressionSet which has been quantile discretized.

   The following code worked without error:

   library(rqubic)
   NROW <- 2189
   NCOL <- 9779
   m = matrix(runif(NROW*NCOL, 0, 10), nrow=NROW)
   s = generateSeeds(m)
   eset <- quantileDiscretize(ExpressionSet(m))
   x = quBicluster(seeds=s, eset=eset, report.no=30)

   In the next release I shall consider making generateSeeds and
quantileDiscretize internal of the quBicluster function. That will
introduce more parameters to quBicluster, but potentially avoiding such
problems that you have met.

   Please let me know if I could further help.

   Best wishees,
David


On Mon, May 12, 2014 at 11:30 AM, Martin Morgan <mtmorgan@fhcrc.org> wrote:

> On 05/11/2014 02:06 AM, Zhang, Jitao David wrote:
>
>> Dear Eric,
>>
>>     Thanks for reporting the issue. I will look into it. Do you mind
>> sending
>> me the data that you used so that I could reproduce the errors?
>>
>
> This does it for me
>
> m = matrix(runif(2189*9779, 0, 10), 2189)
> s = generateSeeds(m)
> x = quBicluster(seeds=s, eset=ExpressionSet(m), report.no=30)
>
> with the segfault at
>
> #7  0x00007f0125643b6a in seed_update (s=0x59851880, ncol=9779,
>     profile=0x11d4ddf0) at bicluster.c:48
> 48        for(i=0;i<ncol;i++) profile[i][s[i]]++;
>
> because s is uninitialized (or overflows?)
>
> (gdb) p i
> $9 = 0
> (gdb) p s[i]
> $10 = -2147483648
>
> Martin
>
>
>>     Best wishes,
>> David
>>
>>
>> On Sun, May 11, 2014 at 9:13 AM, Eric Liaw [guest]
>> <guest@bioconductor.org>wrote:
>>
>>  Hello,
>>>
>>> I ran into a segfault while trying to run rqubic on a 2189x9779 matrix of
>>> integers (actually of mode 'numeric', named "data.exp.discr...") with
>>> values 0 through 6 (not a microarray dataset). I'm not sure if the error
>>> is
>>> in the way I made the rqubicSeeds and ExpressionSet objects from my
>>> matrix,
>>> or something internal to rqubic. The segfault is reproducible and occurs
>>> a
>>> few seconds after calling the function.
>>>
>>> The error message is copied below.
>>>
>>> Thanks,
>>> Eric Liaw
>>> undergraduate student, Stanford University
>>> -------------------------------------
>>>
>>>  data.exprs <- new("ExpressionSet", data) #data is a matrix.
>>>> data.seeds <- generateSeeds(object=data.exprs)
>>>>
>>>
>>> Warning message:
>>> In .local(object, ...) :
>>>    'generateSeeds' requires an matrix of integer. Coerced
>>>
>>>  QUBIC.1 <- quBicluster(seeds=data.seeds, eset=data.exprs, report.no=30)
>>>>
>>>
>>>   *** caught segfault ***
>>> address 0xffffffff1efabdd0, cause 'memory not mapped'
>>>
>>> Traceback:
>>>   1: .Call("qubicluster", seeds = seeds, exprs = exp.leveled, sigma_val =
>>> sigma,     symbols = symbols, report_no = report.no, tolerance_val =
>>> tolerance,     filter_proportion = filter.proportion)
>>>   2: quBiclusterIndex(seeds = seeds, eset = eset, report.no = report.no,
>>>    tolerance = tolerance, filter.proportion = filter.proportion)
>>>   3: quBicluster(seeds = data.seeds,     eset = data.exprs, report.no =
>>> 30)
>>>
>>> Possible actions:
>>> 1: abort (with core dump, if enabled)
>>> 2: normal R exit
>>> 3: exit R without saving workspace
>>> 4: exit R saving workspace
>>>
>>> In quBiclusterIndex(seeds = seeds, eset = eset, report.no = report.no,
>>>  :
>>>    'eset' requires an matrix of integer as the value of 'exprs'. Coerced
>>>
>>>   -- output of sessionInfo():
>>>
>>> R version 2.15.2 (2012-10-26)
>>> Platform: x86_64-pc-linux-gnu (64-bit)
>>>
>>> locale:
>>> [1] C
>>>
>>> attached base packages:
>>> [1] grid      stats     graphics  grDevices utils     datasets  methods
>>> [8] base
>>>
>>> other attached packages:
>>> [1] rqubic_1.4.0       biclust_1.0.2      lattice_0.20-13
>>>   colorspace_1.0-1
>>> [5] MASS_7.3-23        Biobase_2.18.0     BiocGenerics_0.4.0
>>>
>>> loaded via a namespace (and not attached):
>>> [1] tools_2.15.2
>>>
>>>
>>> --
>>> Sent via the guest posting facility at bioconductor.org.
>>>
>>>
>>
>>
>>
>>
>> _______________________________________________
>> Bioconductor mailing list
>> Bioconductor@r-project.org
>> https://stat.ethz.ch/mailman/listinfo/bioconductor
>> Search the archives: http://news.gmane.org/gmane.
>> science.biology.informatics.conductor
>>
>>
>
> --
> Computational Biology / Fred Hutchinson Cancer Research Center
> 1100 Fairview Ave. N.
> PO Box 19024 Seattle, WA 98109
>
> Location: Arnold Building M1 B861
> Phone: (206) 667-2793
>



-- 

*Dr. Jitao David Zhang | **张继涛** | Computational Biology and Bioinformatics
|* *Pharmaceutical Divison | F. Hoffmann-La-Roche AG | CH-4070 Basel |
Switzerland*

*Tel +41 61 688 62 51 *

Confidentiality Note: This message is intended only for ...{{dropped:11}}

