>Say, I invest the time in ggplot2, would it go waste once I want to do
>something in lattice? Or, would this learning help in faster learning
>of lattice? Thanks for your inputs.
Some of the issues that I would consider:
* If you have to work with packages that provide lattice graphs, it might pay to prefer lattice.
* If you have a very programmer-ly mindset, you might prefer lattice, which is more of a "we provide the hooks for you to replace our programming with yours" kind of approach.
* If you prefer a more artistic, mix-n-match approach, ggplot2 is better.
* If you prefer to think of graphing as how you combine and modify things visually, ggplot2 is better. In contrast to the lattice approach which is more programming-like.
* If you prefer the default look of either package, and other factors are equal for you, you might go with that package.
* If you want to make graphs that don't have a straightforward description ("bar chart", "dot plot with smoothing curve", etc), ggplot2 provides more ways to plug things together to make what you want.
* If you want to grab extensions that others have made for specific graph types for specific purposes, you're much more likely to find something that is based on lattice than something that is based on ggplot2.
* Lattice will be included in any R installation that's been done in the last couple of years. GGplot2 is not guaranteed to be installed. (Though, like any R package, installation for an internet-connected machine is fairly easy.)
(Also, lattice is not as new as you seem to believe. Perhaps you're looking at the book publication date, or when it was included as a recommended R package or something else? GGplot came after lattice, and ggplot2 is a refactoring of ggplot, I'm fairly sure.)
Wayne