BaşlayınÜcretsiz Başlayın

Flipping things around

When the labels for our x-axis run into each other, we have two main choices: change the labels to be vertical instead of horizontal or flip the axes. The latter is how the FiveThirtyEight graph did it and makes it easier to read the labels. The plot you created in the previous exercise, titled_plot, has been loaded for you.

Bu egzersiz

Categorical Data in the Tidyverse

kursunun bir parçasıdır
Kursu Görüntüle

Egzersiz talimatları

  • Flip the x- and y-axis.
  • Remove the x-axis ticks.

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

flipped_plot <- titled_plot + 
    # Flip the axes
    ___ + 
    # Remove the x-axis ticks and labels
    ___(___ = element_blank(), 
        ___ = element_blank())
Kodu Düzenle ve Çalıştır