import { AfterContentInit, EventEmitter, QueryList } from '@angular/core'; import { ControlValueAccessor, NgControl } from '@angular/forms'; import * as i0 from "@angular/core"; export declare class EvaluateExperimentVariantsComponent implements ControlValueAccessor, AfterContentInit { winnerVariantFound: EventEmitter; controlsArray: QueryList; onChange: any; onTouched: any; private subscriptions; ngAfterContentInit(): void; /** * Handles changes to the controls in the form. * This method unsubscribes from any previous control subscriptions to prevent memory leaks, * then subscribes to value changes in each control to handle change detection, form validation, * and winner variant evaluation. * * @private */ private handleControlChanges; ngOnDestroy(): void; /** * Retrieves the control names needed for extraction based on available fields. * * @param {Array} fields - The array of field objects. * @returns {Array} - An array of unique control names from the fields. */ getRequiredControlNames(fields: any): unknown[]; /** * Extracts the values of the specified controls from the fields array. * * @param {Array} fields - The array of field objects. * @param {Array} controlNames - The list of control names to extract values for. * @returns {Object} - An object containing the extracted control values. */ extractControlValues(fields: any, controlNames: any): any; writeValue(value: any): void; registerOnChange(fn: any): void; registerOnTouched(fn: any): void; /** * This function evaluates the results of an experiment with multiple variants. It compares the results of the variants * to determine the winner based on the specified goal (e.g., highest result, lowest result) and threshold. If a threshold * is provided, the function will also evaluate whether the winner is clearly above or below the threshold. * * @param {*} variants * @param {*} goal * @param {*} threshold * @returns {object} result */ evaluateExperiment(variants: any, goal: any, threshold?: null): { winner: any; isInconclusive: boolean; evaluation: string; } | { evaluation: string; isInconclusive: boolean; }; /** * This function compares multiple variants to determine the winner based on the specified comparison function. * It iterates over the variants and compares them pairwise to find the overall winner. * @param {*} variants * @param {*} comparisonFunction * @returns An object containing the winner, whether the result is inconclusive, and the evaluation result */ compareVariants(variants: any, comparisonFunction: any): { winner: any; isInconclusive: boolean; evaluation: string; }; /** * This function compares two variants based on the specified comparison function. It returns the variant that is the winner * @param {*} variantA * @param {*} variantB * @param {*} comparisonFunction * @returns An object containing the winner, whether the result is inconclusive, and the evaluation result */ compareTwo(variantA: any, variantB: any, comparisonFunction: any): { isInconclusive: boolean; winner?: undefined; evaluation?: undefined; } | { winner: any; isInconclusive: boolean; evaluation: string; }; /** * This function checks if a variant is valid. A valid variant must have numeric values for minValue, maxValue, and result. * * @param {*} variant * @returns {boolean} True if the variant is valid, false otherwise */ isValidVariant(variant: any): any; /** * This function creates a threshold variant with the specified threshold value. * @param {*} threshold The threshold value to use * @returns A threshold variant object */ createThresholdVariant(threshold: any): { minValue: any; maxValue: any; resultPercentage: any; result: number; id: string; }; /** * This function evaluates the comparison result against the threshold value. * If the winner is the threshold variant, it returns "CLEARLY_BELOW". * If the winner is not the threshold variant, it returns "WINNER". * If there is no winner, it returns "INCONCLUSIVE". * @param {*} comparison The comparison result object * @returns An object containing the winner, the evaluation result, and whether the result is inconclusive */ evaluateAgainstThreshold(comparison: any): { evaluation: string; isInconclusive: boolean; winner?: undefined; } | { winner: any; evaluation: string; isInconclusive: boolean; }; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; }