Package index
Accuracy
The accuracy
module provides functions for converting between accuracy and scale parameters.
-
accuracy_to_discrete_gaussian_scale()
- Convert a desired
accuracy
(tolerance) into a discrete gaussian noise scale at a statistical significance levelalpha
.
-
accuracy_to_discrete_laplacian_scale()
- Convert a desired
accuracy
(tolerance) into a discrete Laplacian noise scale at a statistical significance levelalpha
.
-
accuracy_to_gaussian_scale()
- Convert a desired
accuracy
(tolerance) into a gaussian noise scale at a statistical significance levelalpha
.
-
accuracy_to_laplacian_scale()
- Convert a desired
accuracy
(tolerance) into a Laplacian noise scale at a statistical significance levelalpha
.
-
discrete_gaussian_scale_to_accuracy()
- Convert a discrete gaussian scale into an accuracy estimate (tolerance) at a statistical significance level
alpha
.
-
discrete_laplacian_scale_to_accuracy()
- Convert a discrete Laplacian scale into an accuracy estimate (tolerance) at a statistical significance level
alpha
.
-
gaussian_scale_to_accuracy()
- Convert a gaussian scale into an accuracy estimate (tolerance) at a statistical significance level
alpha
.
-
laplacian_scale_to_accuracy()
- Convert a Laplacian scale into an accuracy estimate (tolerance) at a statistical significance level
alpha
.
Combinators
The combinators
module provides functions for combining transformations and measurements.
-
make_basic_composition()
- basic composition constructor
-
make_chain_mt()
- chain mt constructor
-
make_chain_pm()
- chain pm constructor
-
make_chain_tt()
- chain tt constructor
-
make_fix_delta()
- fix delta constructor
-
make_population_amplification()
- population amplification constructor
-
make_pureDP_to_fixed_approxDP()
- pureDP to fixed approxDP constructor
-
make_pureDP_to_zCDP()
- pureDP to zCDP constructor
-
make_sequential_composition()
- sequential composition constructor
-
make_zCDP_to_approxDP()
- zCDP to approxDP constructor
-
then_basic_composition()
- partial basic composition constructor
-
then_chain_mt()
- partial chain mt constructor
-
then_chain_pm()
- partial chain pm constructor
-
then_chain_tt()
- partial chain tt constructor
-
then_fix_delta()
- partial fix delta constructor
-
then_population_amplification()
- partial population amplification constructor
-
then_pureDP_to_fixed_approxDP()
- partial pureDP to fixed approxDP constructor
-
then_pureDP_to_zCDP()
- partial pureDP to zCDP constructor
-
then_sequential_composition()
- partial sequential composition constructor
-
then_zCDP_to_approxDP()
- partial zCDP to approxDP constructor
Core
The core
module provides functions for accessing the fields of transformations and measurements.
-
function_eval()
- Eval the
function
witharg
.
-
measurement_check()
- Check the privacy relation of the
measurement
at the givend_in
,d_out
-
measurement_function()
- Get the function from a measurement.
-
measurement_input_carrier_type()
- Get the input (carrier) data type of
this
.
-
measurement_input_distance_type()
- Get the input distance type of
measurement
.
-
measurement_input_domain()
- Get the input domain from a
measurement
.
-
measurement_input_metric()
- Get the input domain from a
measurement
.
-
measurement_invoke()
- Invoke the
measurement
witharg
. Returns a differentially private release.
-
measurement_map()
- Use the
measurement
to map a givend_in
tod_out
.
-
measurement_output_distance_type()
- Get the output distance type of
measurement
.
-
measurement_output_measure()
- Get the output domain from a
measurement
.
-
queryable_eval()
- Invoke the
queryable
withquery
. Returns a differentially private release.
-
queryable_query_type()
- Get the query type of
queryable
.
-
transformation_check()
- Check the privacy relation of the
measurement
at the givend_in
,d_out
-
transformation_function()
- Get the function from a transformation.
-
transformation_input_carrier_type()
- Get the input (carrier) data type of
this
.
-
transformation_input_distance_type()
- Get the input distance type of
transformation
.
-
transformation_input_domain()
- Get the input domain from a
transformation
.
-
transformation_input_metric()
- Get the input domain from a
transformation
.
-
transformation_invoke()
- Invoke the
transformation
witharg
. Returns a differentially private release.
-
transformation_map()
- Use the
transformation
to map a givend_in
tod_out
.
-
transformation_output_distance_type()
- Get the output distance type of
transformation
.
-
transformation_output_domain()
- Get the output domain from a
transformation
.
-
transformation_output_metric()
- Get the output domain from a
transformation
.
-
atom_domain()
- Construct an instance of
AtomDomain
.
-
bitvector_domain()
- Construct an instance of
BitVectorDomain
.
-
domain_carrier_type()
- Get the carrier type of a
domain
.
-
domain_debug()
- Debug a
domain
.
-
domain_type()
- Get the type of a
domain
.
-
map_domain()
- Construct an instance of
MapDomain
.
-
member()
- Check membership in a
domain
.
-
option_domain()
- Construct an instance of
OptionDomain
.
-
vector_domain()
- Construct an instance of
VectorDomain
.
Measurements
The measurements
module provides functions that apply calibrated noise to data to ensure differential privacy.
-
debias_randomized_response_bitvec()
- Convert a vector of randomized response bitvec responses to a frequency estimate
-
make_alp_queryable()
- alp queryable constructor
-
make_gaussian()
- gaussian constructor
-
make_geometric()
- geometric constructor
-
make_laplace()
- laplace constructor
-
make_laplace_threshold()
- laplace threshold constructor
-
make_randomized_response()
- randomized response constructor
-
make_randomized_response_bitvec()
- randomized response bitvec constructor
-
make_randomized_response_bool()
- randomized response bool constructor
-
make_report_noisy_max_gumbel()
- report noisy max gumbel constructor
-
then_alp_queryable()
- partial alp queryable constructor
-
then_gaussian()
- partial gaussian constructor
-
then_geometric()
- partial geometric constructor
-
then_laplace()
- partial laplace constructor
-
then_laplace_threshold()
- partial laplace threshold constructor
-
then_randomized_response()
- partial randomized response constructor
-
then_randomized_response_bitvec()
- partial randomized response bitvec constructor
-
then_randomized_response_bool()
- partial randomized response bool constructor
-
then_report_noisy_max_gumbel()
- partial report noisy max gumbel constructor
Measures
The measures
modules provides functions that measure the distance between probability distributions.
-
fixed_smoothed_max_divergence()
- Construct an instance of the
FixedSmoothedMaxDivergence
measure.
-
max_divergence()
- Construct an instance of the
MaxDivergence
measure.
-
measure_debug()
- Debug a
measure
.
-
measure_distance_type()
- Get the distance type of a
measure
.
-
measure_type()
- Get the type of a
measure
.
-
smoothed_max_divergence()
- Construct an instance of the
SmoothedMaxDivergence
measure.
-
user_divergence()
- Construct a new UserDivergence. Any two instances of an UserDivergence are equal if their string descriptors are equal.
-
zero_concentrated_divergence()
- Construct an instance of the
ZeroConcentratedDivergence
measure.
Metrics
The metrics
module provides fuctions that measure the distance between two elements of a domain.
-
absolute_distance()
- Construct an instance of the
AbsoluteDistance
metric.
-
change_one_distance()
- Construct an instance of the
ChangeOneDistance
metric.
-
discrete_distance()
- Construct an instance of the
DiscreteDistance
metric.
-
hamming_distance()
- Construct an instance of the
HammingDistance
metric.
-
insert_delete_distance()
- Construct an instance of the
InsertDeleteDistance
metric.
-
l1_distance()
- Construct an instance of the
L1Distance
metric.
-
l2_distance()
- Construct an instance of the
L2Distance
metric.
-
linf_distance()
- Construct an instance of the
LInfDistance
metric.
-
metric_debug()
- Debug a
metric
.
-
metric_distance_type()
- Get the distance type of a
metric
.
-
metric_type()
- Get the type of a
metric
.
-
partition_distance()
- Construct an instance of the
PartitionDistance
metric.
-
symmetric_distance()
- Construct an instance of the
SymmetricDistance
metric.
-
user_distance()
- Construct a new UserDistance. Any two instances of an UserDistance are equal if their string descriptors are equal.
Mod
The mod
module provides the classes which implement the OpenDP Programming Framework, as well as utilities for enabling features and finding parameter values.
-
binary_search()
- Find the closest passing value to the decision boundary of
predicate
-
binary_search_chain()
- Find the highest-utility (
d_in
,d_out
)-close Transformation or Measurement.
-
binary_search_param()
- Solve for the ideal constructor argument to
make_chain
-
disable_features()
- Disable features in the opendp package.
-
enable_features()
- Enable features for the opendp package.
-
hashitems()
- extract heterogeneously typed keys and values from a hashtab
-
new_domain()
- new domain
-
new_function()
- new function
-
new_hashtab()
- create an instance of a hashtab from keys and values
-
new_measure()
- new measure
-
new_measurement()
- new measurement
-
new_metric()
- new metric
-
new_queryable()
- new queryable
-
new_smd_curve()
- new Smoothed Max Divergence curve
-
new_transformation()
- new transformation
Transformations
The transformations
module provides functions that deterministicly transform datasets.
-
choose_branching_factor()
- Returns an approximation to the ideal
branching_factor
for a dataset of a given size, that minimizes error in cdf and quantile estimates based on b-ary trees.
-
make_b_ary_tree()
- b ary tree constructor
-
make_bounded_float_checked_sum()
- bounded float checked sum constructor
-
make_bounded_float_ordered_sum()
- bounded float ordered sum constructor
-
make_bounded_int_monotonic_sum()
- bounded int monotonic sum constructor
-
make_bounded_int_ordered_sum()
- bounded int ordered sum constructor
-
make_bounded_int_split_sum()
- bounded int split sum constructor
-
make_cast()
- cast constructor
-
make_cast_default()
- cast default constructor
-
make_cast_inherent()
- cast inherent constructor
-
make_cdf()
- cdf constructor
-
make_clamp()
- clamp constructor
-
make_consistent_b_ary_tree()
- consistent b ary tree constructor
-
make_count()
- count constructor
-
make_count_by()
- count by constructor
-
make_count_by_categories()
- count by categories constructor
-
make_count_distinct()
- count distinct constructor
-
make_create_dataframe()
- create dataframe constructor
-
make_df_cast_default()
- df cast default constructor
-
make_df_is_equal()
- df is equal constructor
-
make_drop_null()
- drop null constructor
-
make_find()
- find constructor
-
make_find_bin()
- find bin constructor
-
make_identity()
- identity constructor
-
make_impute_constant()
- impute constant constructor
-
make_impute_uniform_float()
- impute uniform float constructor
-
make_index()
- index constructor
-
make_is_equal()
- is equal constructor
-
make_is_null()
- is null constructor
-
make_lipschitz_float_mul()
- lipschitz float mul constructor
-
make_mean()
- mean constructor
-
make_metric_bounded()
- metric bounded constructor
-
make_metric_unbounded()
- metric unbounded constructor
-
make_ordered_random()
- ordered random constructor
-
make_quantile_score_candidates()
- quantile score candidates constructor
-
make_quantiles_from_counts()
- quantiles from counts constructor
-
make_resize()
- resize constructor
-
make_select_column()
- select column constructor
-
make_sized_bounded_float_checked_sum()
- sized bounded float checked sum constructor
-
make_sized_bounded_float_ordered_sum()
- sized bounded float ordered sum constructor
-
make_sized_bounded_int_checked_sum()
- sized bounded int checked sum constructor
-
make_sized_bounded_int_monotonic_sum()
- sized bounded int monotonic sum constructor
-
make_sized_bounded_int_ordered_sum()
- sized bounded int ordered sum constructor
-
make_sized_bounded_int_split_sum()
- sized bounded int split sum constructor
-
make_split_dataframe()
- split dataframe constructor
-
make_split_lines()
- split lines constructor
-
make_split_records()
- split records constructor
-
make_subset_by()
- subset by constructor
-
make_sum()
- sum constructor
-
make_sum_of_squared_deviations()
- sum of squared deviations constructor
-
make_unordered()
- unordered constructor
-
make_variance()
- variance constructor
-
then_b_ary_tree()
- partial b ary tree constructor
-
then_bounded_float_checked_sum()
- partial bounded float checked sum constructor
-
then_bounded_float_ordered_sum()
- partial bounded float ordered sum constructor
-
then_bounded_int_monotonic_sum()
- partial bounded int monotonic sum constructor
-
then_bounded_int_ordered_sum()
- partial bounded int ordered sum constructor
-
then_bounded_int_split_sum()
- partial bounded int split sum constructor
-
then_cast()
- partial cast constructor
-
then_cast_default()
- partial cast default constructor
-
then_cast_inherent()
- partial cast inherent constructor
-
then_cdf()
- partial cdf constructor
-
then_clamp()
- partial clamp constructor
-
then_consistent_b_ary_tree()
- partial consistent b ary tree constructor
-
then_count()
- partial count constructor
-
then_count_by()
- partial count by constructor
-
then_count_by_categories()
- partial count by categories constructor
-
then_count_distinct()
- partial count distinct constructor
-
then_create_dataframe()
- partial create dataframe constructor
-
then_df_cast_default()
- partial df cast default constructor
-
then_df_is_equal()
- partial df is equal constructor
-
then_drop_null()
- partial drop null constructor
-
then_find()
- partial find constructor
-
then_find_bin()
- partial find bin constructor
-
then_identity()
- partial identity constructor
-
then_impute_constant()
- partial impute constant constructor
-
then_impute_uniform_float()
- partial impute uniform float constructor
-
then_index()
- partial index constructor
-
then_is_equal()
- partial is equal constructor
-
then_is_null()
- partial is null constructor
-
then_lipschitz_float_mul()
- partial lipschitz float mul constructor
-
then_mean()
- partial mean constructor
-
then_metric_bounded()
- partial metric bounded constructor
-
then_metric_unbounded()
- partial metric unbounded constructor
-
then_ordered_random()
- partial ordered random constructor
-
then_quantile_score_candidates()
- partial quantile score candidates constructor
-
then_quantiles_from_counts()
- partial quantiles from counts constructor
-
then_resize()
- partial resize constructor
-
then_select_column()
- partial select column constructor
-
then_sized_bounded_float_checked_sum()
- partial sized bounded float checked sum constructor
-
then_sized_bounded_float_ordered_sum()
- partial sized bounded float ordered sum constructor
-
then_sized_bounded_int_checked_sum()
- partial sized bounded int checked sum constructor
-
then_sized_bounded_int_monotonic_sum()
- partial sized bounded int monotonic sum constructor
-
then_sized_bounded_int_ordered_sum()
- partial sized bounded int ordered sum constructor
-
then_sized_bounded_int_split_sum()
- partial sized bounded int split sum constructor
-
then_split_dataframe()
- partial split dataframe constructor
-
then_split_lines()
- partial split lines constructor
-
then_split_records()
- partial split records constructor
-
then_subset_by()
- partial subset by constructor
-
then_sum()
- partial sum constructor
-
then_sum_of_squared_deviations()
- partial sum of squared deviations constructor
-
then_unordered()
- partial unordered constructor
-
then_variance()
- partial variance constructor
Typing
The typing
module provides utilities that bridge between R and Rust types. OpenDP relies on precise descriptions of data types to make its security guarantees: These are more natural in Rust with its fine-grained type system, but they may feel out of place in R. These utilities try to fill that gap.
-
BitVector
- type signature for a BitVector
-
String
- type signature for a string
-
bool
- type signature for a boolean
-
f32
- type signature for a 32-bit floating point number
-
f64
- type signature for a 64-bit floating point number
-
i128
- type signature for a 128-bit signed integer
-
i16
- type signature for a 16-bit signed integer
-
i32
- type signature for a 32-bit signed integer
-
i64
- type signature for a 64-bit signed integer
-
i8
- type signature for an 8-bit signed integer
-
u128
- type signature for a 128-bit unsigned integer
-
u16
- type signature for a 16-bit unsigned integer
-
u32
- type signature for a 32-bit unsigned integer
-
u64
- type signature for a 64-bit unsigned integer
-
u8
- type signature for an 8-bit unsigned integer
-
usize
- type signature for a pointer-sized unsigned integer
Other
This should be empty if correctly configured. Please file an issue if any functions are listed here.