0

I want to plot a table of my data frame with lines and color formatting. So far the only solution I have come up with is through packages xtables and data.table but I seem to get the output in Latex code.

  1. How do I output this code in R to see what it looks like?

  2. Is there no simple solution for plotting a table with the base package?

Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Mickson
  • 43
  • 6
  • 1
    Please make your question [reproducible](http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example). – talat Nov 17 '14 at 08:05

1 Answers1

0

Use plot function. For example data set iris, which is available in R by default. There are 5 columns there.

  Sepal.Length Sepal.Width Petal.Length Petal.Width Species
1          5.1         3.5          1.4         0.2  setosa
2          4.9         3.0          1.4         0.2  setosa
3          4.7         3.2          1.3         0.2  setosa
4          4.6         3.1          1.5         0.2  setosa
5          5.0         3.6          1.4         0.2  setosa
6          5.4         3.9          1.7         0.4  setosa

You can plot it using

plot(Sepal.Length ~ Sepal.Width, data = iris)

Cron Merdek
  • 1,084
  • 1
  • 14
  • 25