Skip to content

Commit

Permalink
fix examples
Browse files Browse the repository at this point in the history
  • Loading branch information
gilbertocamara committed Nov 1, 2023
1 parent 4367a05 commit ea3deb7
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 14 deletions.
6 changes: 4 additions & 2 deletions R/sits_classify.R
Original file line number Diff line number Diff line change
Expand Up @@ -133,14 +133,16 @@
#' ml_model = rf_model,
#' output_dir = tempdir(),
#' n_sam_pol = 20,
#' multicores = 4
#' multicores = 4,
#' version = "segs_classify"
#' )
#' # Create a labelled vector cube
#' class_segs <- sits_label_classification(
#' cube = probs_segs,
#' output_dir = tempdir(),
#' multicores = 2,
#' memsize = 4
#' memsize = 4,
#' version = "segs_classify"
#' )
#' # plot class_segs
#' plot(class_segs)
Expand Down
2 changes: 0 additions & 2 deletions R/sits_plot.R
Original file line number Diff line number Diff line change
Expand Up @@ -1380,8 +1380,6 @@ plot.som_map <- function(x, y, ..., type = "codes", band = 1) {
#' xgb_model <- sits_train(samples_modis_ndvi,
#' ml_method = sits_xgboost()
#' )
#' # plot the model
#' plot(xgb_model)
#' }
#' @export
#'
Expand Down
9 changes: 6 additions & 3 deletions R/sits_segmentation.R
Original file line number Diff line number Diff line change
Expand Up @@ -209,20 +209,23 @@ sits_segment <- function(cube,
#' # segment the vector cube
#' segments <- sits_segment(
#' cube = cube,
#' output_dir = tempdir()
#' output_dir = tempdir(),
#' version = "slic-demo"
#' )
#' # create a classification model
#' rfor_model <- sits_train(samples_modis_ndvi, sits_rfor())
#' # classify the segments
#' seg_probs <- sits_classify(
#' data = segments,
#' ml_model = rfor_model,
#' output_dir = tempdir()
#' output_dir = tempdir(),
#' version = "slic-demo"
#' )
#' # label the probability segments
#' seg_label <- sits_label_classification(
#' cube = seg_probs,
#' output_dir = tempdir()
#' output_dir = tempdir(),
#' version = "slic-demo"
#' )
#' }
#' @export
Expand Down
2 changes: 0 additions & 2 deletions man/plot.xgb_model.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions man/sits_classify.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions man/sits_slic.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit ea3deb7

Please sign in to comment.