Thank you Ben, this also works! I have a copy of the Sarkar but,
usually, I don't work with histograms. I'll brush it up, then. Best
regards, Luigi
On Thu, Jun 7, 2018 at 1:43 PM Ben Tupper wrote:
>
> Hi again,
>
> I'm sort of pre-coffee still, but does this do it? The data frame only has
> one
Hi again,
I'm sort of pre-coffee still, but does this do it? The data frame only has one
variable, a factor where the order of the levels is specified.
library(lattice)
group <- c("a", "b", "c", "d", "e")
freq<- c(1, 2, 2, 5, 3)
x <- rep(group, freq)
df <- data.frame(group = fa
also, with this approach, I need to re-arrange the data. Is it
possible to work directly on a dataframe?
On Thu, Jun 7, 2018 at 12:48 PM Ben Tupper wrote:
>
> Hi,
>
> Is this what you are after?
>
> group <- c("a", "b", "c", "d", "e")
> freq <-c(1, 2, 2, 5, 3)
> x = rep(group, freq)
> barplot(tabl
exactly! Thank you!
but it is possible to do it with lattice? I might have an extra level
of information, for instance super-group, and in that case, I could
plot all the supergroup easily together.
On Thu, Jun 7, 2018 at 12:48 PM Ben Tupper wrote:
>
> Hi,
>
> Is this what you are after?
>
> group
Hi,
Is this what you are after?
group <- c("a", "b", "c", "d", "e")
freq <-c(1, 2, 2, 5, 3)
x = rep(group, freq)
barplot(table(x))
Cheers,
Ben
> On Jun 7, 2018, at 6:00 AM, Luigi Marongiu wrote:
>
> Dear all,
> I have a dataframe with a column representing the names of the
> elements (a, b
Dear all,
I have a dataframe with a column representing the names of the
elements (a, b, etc) and one with their frequencies.
How can I plot the frequencies so that each element has an associated
frequency value?
I have been thinking of a histogram, but I have found it difficult to
implement. I hav
6 matches
Mail list logo