Skip to content

Releases: dieghernan/tidyterra

tidyterra 1.1.0

11 Mar 07:37

Choose a tag to compare

  • New dplyr minimum version: 1.2.0.

New Methods

  • add_count.SpatVector() (#195).
  • filter_out.SpatVector() (#196).

Changes in arguments

  • In dplyr 1.2.0 .by has moved from experimental to stable. In summarise.SpatVector() this was implemented in version 1.0.0. Now it has been extended to the following tidyterra methods as new arguments
    (#193):
    • mutate.SpatVector().
    • filter.SpatVector().
    • ?slice.Spat methods for SpatVector.
    • fill.SpatVector().
  • Other arguments added to methods:
    • ?mutate.Spat: New arguments .keep, .before, .after (see
      dplyr::mutate()).
    • arrange.SpatVector(): .locale added (see dplyr::arrange()).
    • filter.SpatVector(): .preserve argument support added (previously it was ignored).
      • In count.SpatVector():
        • wt argument for performing weighted counts supported.
        • .drop argument deprecated, (it never really worked).

Deprecations

  • ?transmute.Spat is marked as superseded, as in dplyr::transmute()
    dplyr 1.1.0 (January 2023). Use mutate(.keep = "none").

Other changes

  • Migrate vignettes and articles to Quarto.

What's Changed

Full Changelog: v1.0.0...v1.1.0

tidyterra 1.0.0

23 Jan 07:12

Choose a tag to compare

  • Minimal R version required updated to >= 4.1.0.
  • Minimal ggplot2 version required >= 4.0.0.
  • Adapt deprecation of ggplot2 (4.0.0):
    • geom_spatvector_label() / geom_spatvector_text(): label.size
      aesthetic replaced by linewidth. Also nudge_x and nudge_y are not
      explicitly documented and are passed to ggplot2::geom_sf_label() /
      _text() via dots (...).
  • get_coltab_pal() can extract colors with alpha values (#180).
  • New dependency generics added to Imports. New methods (SpatRaster,
    SpatVector, SpatGraticule, SpatExtent) included:
    • tidy.SpatRaster(), etc.
    • glance.SpatRaster(), etc.
    • required_pkgs.SpatRaster(), etc.
  • fortify.Spat methods now uses tidy.Spat methods under the hood:
    • New fortify.SpatExtent() method.
  • New autoplot.SpatExtent() and autoplot.SpatGraticule() methods.
  • summarise.SpatVector() supports now the .by argument.
  • geom_spatraster_contour_text() is now a stable function.
  • testthat: Internal changes in tests:
    • Move snapshot testing to its own directory, that is included in
      .Rbuildignore: ./tests/testthat/test_ci.

What's Changed

Full Changelog: v0.7.2...v1.0.0

tidyterra 0.7.2

14 Apr 19:10

Choose a tag to compare

  • Hotfix: Correct error on tests for CRAN.

What's Changed

Full Changelog: v0.7.1...v0.7.2

tidyterra 0.7.1

07 Apr 18:11

Choose a tag to compare

  • New parameters in geom_spatraster_*: mask_projection. When set to TRUE
    avoid SpatRaster to wrapping around on some projections (see #115 and
    #169, by @dramanica).
  • Fix an old bug exposed after terra 1.8-42: Plots crash when using
    ggplot2::facet_wrap() in combination with coord_sf() (or with implicit
    change of CRS due to other sf/Spat* objects).

What's Changed

New Contributors

Full Changelog: v0.7.0...v0.7.1

tidyterra 0.7.0

03 Feb 21:04

Choose a tag to compare

  • Minimal version of terra required is 1.8-10.
  • Remove metR from Suggests.
  • Improve handling of factors when several layers have different levels. This
    is done using terra::combineLevels() (terra >= 1.8-10). See
    https://stackoverflow.com/questions/79340152.
  • Now scales that uses limits truncate the legend when limits parameter is
    provided (#165 @Fan-iX). Scales impacted:
    • scale_*_cross_blended_tint_c and scale_*_cross_blended_tint_b.
    • scale_*_hypso_tint_c and scale_*_hypso_tint_b.
    • scale_*_grass_c and scale_*_grass_b.
  • Now geom_spatraster() (and overall pivoting of SpatRaster is less strict
    with different layer classes: if several layers can be defined as numeric
    (i.e. double, integer and numeric) the pivoting (and therefore the
    plot) can be performed. This is consistent with tidyr::pivot_longer()
    behavior (https://stackoverflow.com/questions/79292989).

What's Changed

  • Bump dieghernan/cran-status-check from 1 to 2 by @dependabot in #163
  • Handling different levels on factor layers by @dieghernan in #164
  • Avoid tint color shift caused by the limits parameter in scale_*_hypso_tint_b and scale_*_hypso_tint_c by @Fan-iX in #165
  • Expand PR #165 to other scales, tests and document by @dieghernan in #166
  • Soften checks on mixed types by @dieghernan in #167

New Contributors

Full Changelog: v0.6.2...v0.7.0

tidyterra 0.6.2

08 Jan 10:48

Choose a tag to compare

  • Add (limited) support for SpatGraticule (see terra::graticule()) #155.
  • New arguments in geom_spatraster_rgb(): stretch and zlim. See
    terra::plotRGB() for clarification.
  • geom_spatraster() suggests geom_spatraster_rgb() when a SpatRaster
    with RGB specification is detected (terra::has.RGB() is TRUE)

What's Changed

Full Changelog: v0.6.1...v0.6.2

tidyterra 0.6.1

08 Jun 10:02

Choose a tag to compare

  • Add new scales:
    • grass_db and scale_fill_grass_c() family. This is an implementation
      of terra::map.pal(), that is the default palette for terra::plot()
      (> 1.7.78).
    • autoplot.SpatRaster() now uses also grass_db as the default palette.
    • Add scale_fill_princess_c() scale family.
  • Fix tests.

What's Changed

Full Changelog: v0.6.0...v0.6.1

tidyterra 0.6.0

23 Apr 03:51

Choose a tag to compare

  • Requires ggplot2 (>= 3.5.0).
  • New methods for SpatVector objects:
    • pivot_longer.SpatVector() and pivot_wider.SpatVector().
    • fill.SpatVector().
  • New geom geom_spatraster_contour_text() implemented on top of
    isoband::isolines_grob()
    Experimental.
  • glimpse.SpatRaster() and glimpse.SpatVector() now displays information
    using ?tibble::print.tbl_df approach for the header and the footer. The
    body is still displayed transposed as of dplyr::glimpse(). See
    pillar::tbl_format_header() and pillar::tbl_format_footer() for
    examples.
  • as_sf() converts a SpatVector to a sf object with an additional
    tbl_df class for pretty printing.
  • fortify.SpatRaster() gains a new argument pivot that allows better
    integration with other ggplot2 geoms when pivoting. This is a wrapper of
    tidyr::pivot_longer().
  • Tidy documentation.
  • metR added to Suggests.

What's Changed

Full Changelog: v0.5.2...v0.6.0

tidyterra 0.5.2

19 Jan 13:17

Choose a tag to compare

  • Adapt tests to ggplot2 3.5.0 (#129) @teunbrand.
  • Reduce package size, specially relevant in the external raster asia.tif.

What's Changed

New Contributors

Full Changelog: v0.5.1...v0.5.2

tidyterra 0.5.1

15 Dec 12:04

Choose a tag to compare

  • Adjust tests for as_sf() (#124).

What's Changed

Full Changelog: v0.5.0...v0.5.1