The Yosemite Museum has a small geological collection that represents the overarching geology of the park. Ranger-naturalists from the Yosemite Field School collected many of the park's specimens during the first half of the 20th century. (Collecting rocks within national parks is illegal without a research permit.)
Like the park, the collection largely contains plutonic rocks. The predominant rock type is granite, with a large variety representing the diversity of mineral composition and location. The collection also contains other kinds of granitic rocks from all over the park, including pegmatite and porphyry. In addition, the collection also has larger pieces of the minerals that form these rocks, such as quartz, scheelite, orthoclase, calcite, barite, and hornblende.
The collection also houses some volcanic rocks, with a few lava specimens collected around the Rancheria Mountains; basalt, volcanic ash, and andesite breccias from Mount Dana; and some pumice and obsidian specimens largely collected in regions outside the park, such as the Mono Lake area.
Other Geologic Features
The collection also houses a few specimens with evidence of change over time, such as water erosion and glacial carving.
The museum contains a very small paleontological collection, largely consisting of petrified wood, with specimens from the northern park border and Miocene lahar deposits west of Hetch Hetchy. The collection also contains some shell, crinoid, and coral fossils found near and just outside of the park's eastern border.
More about Yosemite's geology...
Yosemite Nature Notes has an episode about Yosemite's granitic rocks, which you can watch below.