Problem
A common issue new users run into is sketching data with leverage_sketch() but keeping the original large object in memory:
sketched <- leverage_sketch(big_obj, sketch_size = 10000)
# big_obj is still in memory, doubling RAM usage!
Proposal
- Add a
@details section to leverage_sketch documenting the idiomatic pattern: input <- leverage_sketch(input, ...) (overwrite in place)
- Add a prominent note in the vignette about freeing the original object
- Consider adding a
cli::cli_alert_warning() after sketching reminding users to remove the original object
Problem
A common issue new users run into is sketching data with
leverage_sketch()but keeping the original large object in memory:Proposal
@detailssection toleverage_sketchdocumenting the idiomatic pattern:input <- leverage_sketch(input, ...)(overwrite in place)cli::cli_alert_warning()after sketching reminding users to remove the original object