[R] colored table
Jeff Newmiller
jdnewmil at dcn.davis.ca.us
Sat May 28 17:10:54 CEST 2016
If you don't mix the text and color, heatmaps are pretty standard presentation techniques.
--
Sent from my phone. Please excuse my brevity.
On May 28, 2016 7:41:53 AM PDT, Bert Gunter <bgunter.4567 at gmail.com> wrote:
>Hi Naresh:
>
>I shall be brief, as discussions of what statistical/graphical
>techniques
>to use are largely OT.
>
>IMO, this is a bad idea. I think the table entries will be very
>difficult
>to read and groc. If the tables are unrelated, use 2 tables. If you
>think
>they might be related, plot the entries of one versus the other in a
>scatter plot. Another possibility would be plot the values as separate
>bars
>in a trellis plot with you table x and y categorical values as
>conditioning
>factors. Judging and comparing bar lengths is much more accurate than
>trying to quantify shading density.
>
>Cheers,
>Bert
>On Sat, May 28, 2016 at 9:12 AM Naresh Gurbuxani <
>naresh_gurbuxani at hotmail.com> wrote:
>
>> I want to print a table where table elements are colored according to
>the
>> frequency of the bin. For example, consider below table.
>>
>> Function values that I would like to print in the table
>>
>> x.eq.minus1 x.eq.zero x.eq.plus1
>> y.eq.minus1 -20 10 -5
>> y.eq.zero -10 6 22
>> y.eq.plus1 -8 10 -14
>>
>>
>> Frequency table to color the above table
>>
>> x.eq.minus1 x.eq.zero x.eq.plus1
>> y.eq.minus1 0.05 0.15 0.1
>> y.eq.zero 0.07 0.3 0.08
>> y.eq.plus1 0.05 0.15 0.05
>>
>>
>> In the resulting table, the element for (x = 0, y = 0) will be 6.
>This
>> will be printed with a dark color background. The element for (x =
>-1, y =
>> -1) will be -20. This will be printed with a light color background.
> And
>> so on.
>>
>> Thanks for your help,
>> Naresh
>>
>> ______________________________________________
>> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
>> 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.
>>
>
> [[alternative HTML version deleted]]
>
>______________________________________________
>R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
>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.
[[alternative HTML version deleted]]
More information about the R-help
mailing list