Data preparation for Poisson regression: use of individual data Most texts I have read about Poisson-regression assumes that the data is available in an already grouped form, i.e. counts are given for each unique covariate combination. For instance, we have (in R)
DataGrouped<-data.frame(Gender=as.factor(c("M","F")),Counts=c(6,2))
DataGrouped
    Gender Counts
  1      M      6
  2      F      2

thus we can use
glm(Counts~Gender,data=DataGrouped,family=poisson)

to run the Poisson-regression.
However, often we have individual-level data, such as
DataIndividual<-data.frame(PatientID=1:8,Gender=as.factor(c(rep("M",6),rep("F",2))))
DataIndividual
    PatientID  Gender
  1         1      M
  2         2      M
  3         3      M
  4         4      M
  5         5      M
  6         6      M
  7         7      F
  8         8      F

which is clearly identical to the above database.
The question is: how can I run the Poisson-regression on such individual-level database?
Of course, I am aware that I could simply do the counting myself, for example with
glm(Freq~Var1,data=data.frame(table(DataIndividual$Gender)),family=poisson)

but I am interested in whether it is possible without an explicit, manual counting. Especially, whether it is possible to somehow interface DataIndividual directly to glm.
 A: There are two answers to this, particularly in light of your example:


*

*The example is clearly an example, where it does not make sense to use Poisson regression. This is data with two categories (which you could regard as 0 or 1), into which each single observation can fall. Using the binomial (or multinomial, if there are more than 2 categories) distribution makes much more sense. Yes, sure for really small proportions assuming a Poisson distribution may give similar answers, but this example is not one where that would be the case.

*In general, if these were data, for which Poisson regression did make sense, you can just dump such observations into Poisson regression software, you just need to decide on what offset to use. The very nature of Poisson regression means that it does not care whether the total count comes from multiple individuals or a single individual. I.e. 10 individuals with counts of 0, 5, 10, 100, 85, 0, 0, 0, 50, 50 in 1 time unit each (log(1) offset in each observation), or a single individual with a count of 300 in 10 time units (log(10) offset in Poisson regression) are exactly the same to Poisson regression. This may be very implausible, because you might assume that there should be between individual variability, but in that case Poisson regression is the wrong tool (negative binomial or a random effects Poisson model would then be preferable).

A: Partially answered in comments.  The main takeaway is this: Yes, this is a problem. Poisson regression needs the data tabled in a way such that covariates is constant in each cell, so using extra covariates in the model ay require retallying the data.  
And, secondary, one should not expect glm (or equivalents in other software than R) to do the tallying. Data can come in many different formats, and (re)arranging the data is a proper format tidying the data should be done prior to analysis. The complications caused by data formats (some discussed in the comments) are orthogonal to the complications of analysis, and should be tackled as a different problem.
