All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.marklogic.client.expression.MathExpr Maven / Gradle / Ivy

The newest version!
/*
 * Copyright © 2024 MarkLogic Corporation. All Rights Reserved.
 */

package com.marklogic.client.expression;

import com.marklogic.client.type.XsAnyAtomicTypeSeqVal;
import com.marklogic.client.type.XsAnyAtomicTypeVal;
import com.marklogic.client.type.XsDoubleSeqVal;
import com.marklogic.client.type.XsDoubleVal;
import com.marklogic.client.type.XsIntegerVal;
import com.marklogic.client.type.XsStringSeqVal;
import com.marklogic.client.type.XsStringVal;

import com.marklogic.client.type.ServerExpression;

// IMPORTANT: Do not edit. This file is generated.

/**
 * Builds expressions to call functions in the math server library for a row
 * pipeline.
 */
public interface MathExpr {
    /**
  * Returns the arc cosine of x, in radians, in the range from 0 to pi (inclusive).
  *
  * 

  * 

* Provides a client interface to the math:acos server function. * @param x The fraction to be evaluated. Must be in the range of -1 to +1 (inclusive). (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression acos(ServerExpression x); /** * Returns the arc sine of x, in radians, in the range from -pi/2 to +pi/2 (inclusive). * * *

* Provides a client interface to the math:asin server function. * @param x The fraction to be evaluated. Must be in the range of -1 to +1 (inclusive). (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression asin(ServerExpression x); /** * Returns the arc tangent of x, in radians. in the range from -pi/2 to +pi/2 (inclusive). * * *

* Provides a client interface to the math:atan server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression atan(ServerExpression x); /** * Returns the arc tangent of y/x, in radians, in the range from -pi/2 to +pi/2 (inclusive), using the signs of y and x to determine the appropriate quadrant. *

* Provides a client interface to the math:atan2 server function. * @param y The floating point dividend. (of xs:double) * @param x The floating point divisor. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression atan2(ServerExpression y, double x); /** * Returns the arc tangent of y/x, in radians, in the range from -pi/2 to +pi/2 (inclusive), using the signs of y and x to determine the appropriate quadrant. * * *

* Provides a client interface to the math:atan2 server function. * @param y The floating point dividend. (of xs:double) * @param x The floating point divisor. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression atan2(ServerExpression y, ServerExpression x); /** * Returns the smallest integer greater than or equal to x. * * *

* Provides a client interface to the math:ceil server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression ceil(ServerExpression x); /** * Returns the Pearson correlation coefficient of a data set. The size of the input array should be 2. The function eliminates all pairs for which either the first element or the second element is empty. After the elimination, if the length of the input is less than 2, the function returns the empty sequence. After the elimination, if the standard deviation of the first column or the standard deviation of the second column is 0, the function returns the empty sequence. * * *

* Provides a client interface to the math:correlation server function. * @param arg The input data set. Each array should contain a pair of values. (of json:array) * @return a server expression with the xs:double server data type */ public ServerExpression correlation(ServerExpression arg); /** * Returns the cosine of x, in the range from -1 to +1 (inclusive). * * *

* Provides a client interface to the math:cos server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression cos(ServerExpression x); /** * Returns the hyperbolic cosine of x. * * *

* Provides a client interface to the math:cosh server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression cosh(ServerExpression x); /** * Returns the cotangent of x. * * *

* Provides a client interface to the math:cot server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression cot(ServerExpression x); /** * Returns the sample covariance of a data set. The size of the input array should be 2. The function eliminates all pairs for which either the first element or the second element is empty. After the elimination, if the length of the input is less than 2, the function returns the empty sequence. * * *

* Provides a client interface to the math:covariance server function. * @param arg The input data set. Each array should contain a pair of values. (of json:array) * @return a server expression with the xs:double server data type */ public ServerExpression covariance(ServerExpression arg); /** * Returns the population covariance of a data set. The size of the input array should be 2. The function eliminates all pairs for which either the first element or the second element is empty. After the elimination, if the length of the input is 0, the function returns the empty sequence. * * *

* Provides a client interface to the math:covariance-p server function. * @param arg The input data set. Each array should contain a pair of values. (of json:array) * @return a server expression with the xs:double server data type */ public ServerExpression covarianceP(ServerExpression arg); /** * Returns numeric expression converted from radians to degrees. * * *

* Provides a client interface to the math:degrees server function. * @param x An angle expressed in radians. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression degrees(ServerExpression x); /** * Returns e (approximately 2.71828182845905) to the xth power. * * *

* Provides a client interface to the math:exp server function. * @param x The exponent to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression exp(ServerExpression x); /** * Returns the absolute value of x. * * *

* Provides a client interface to the math:fabs server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression fabs(ServerExpression x); /** * Returns the largest integer less than or equal to x. * * *

* Provides a client interface to the math:floor server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression floor(ServerExpression x); /** * Returns the remainder of x/y. *

* Provides a client interface to the math:fmod server function. * @param x The floating point dividend. (of xs:double) * @param y The floating point divisor. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression fmod(ServerExpression x, double y); /** * Returns the remainder of x/y. * * *

* Provides a client interface to the math:fmod server function. * @param x The floating point dividend. (of xs:double) * @param y The floating point divisor. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression fmod(ServerExpression x, ServerExpression y); /** * Returns x broken up into mantissa and exponent, where x = mantissa*2^exponent. * * *

* Provides a client interface to the math:frexp server function. * @param x The exponent to be evaluated. (of xs:double) * @return a server expression with the item server data type */ public ServerExpression frexp(ServerExpression x); /** * Returns x*2^i. *

* Provides a client interface to the math:ldexp server function. * @param y The floating-point number to be multiplied. (of xs:double) * @param i The exponent integer. (of xs:integer) * @return a server expression with the xs:double server data type */ public ServerExpression ldexp(ServerExpression y, long i); /** * Returns x*2^i. * * *

* Provides a client interface to the math:ldexp server function. * @param y The floating-point number to be multiplied. (of xs:double) * @param i The exponent integer. (of xs:integer) * @return a server expression with the xs:double server data type */ public ServerExpression ldexp(ServerExpression y, ServerExpression i); /** * Returns a linear model that fits the given data set. The size of the input array should be 2, as currently only simple linear regression model is supported. The first element of the array should be the value of the dependent variable while the other element should be the value of the independent variable. * * *

* Provides a client interface to the math:linear-model server function. * @param arg The input data set. Each array should contain a pair of values. (of json:array) * @return a server expression with the math:linear-model server data type */ public ServerExpression linearModel(ServerExpression arg); /** * Returns the coefficients of the linear model. Currently only simple linear regression model is supported so the return should contain only one coefficient (also called "slope"). * * *

* Provides a client interface to the math:linear-model-coeff server function. * @param linearModel A linear model. (of math:linear-model) * @return a server expression with the xs:double server data type */ public ServerExpression linearModelCoeff(ServerExpression linearModel); /** * Returns the intercept of the linear model. * * *

* Provides a client interface to the math:linear-model-intercept server function. * @param linearModel A linear model. (of math:linear-model) * @return a server expression with the xs:double server data type */ public ServerExpression linearModelIntercept(ServerExpression linearModel); /** * Returns the R^2 value of the linear model. * * *

* Provides a client interface to the math:linear-model-rsquared server function. * @param linearModel A linear model. (of math:linear-model) * @return a server expression with the xs:double server data type */ public ServerExpression linearModelRsquared(ServerExpression linearModel); /** * Returns the base-e logarithm of x. * * *

* Provides a client interface to the math:log server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression log(ServerExpression x); /** * Returns the base-10 logarithm of x. * * *

* Provides a client interface to the math:log10 server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression log10(ServerExpression x); /** * Returns the median of a sequence of values. The function returns the empty sequence if the input is the empty sequence. * * *

* Provides a client interface to the math:median server function. * @param arg The sequence of values. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression median(ServerExpression arg); /** * Returns the mode of a sequence. The mode is the value that occurs most frequently in a data set. If no value occurs more than once in the data set, the function returns the empty sequence. If the input is the empty sequence, the function returns the empty sequence. * * *

* Provides a client interface to the math:mode server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @return a server expression with the xs:anyAtomicType server data type */ public ServerExpression mode(ServerExpression arg); /** * Returns the mode of a sequence. The mode is the value that occurs most frequently in a data set. If no value occurs more than once in the data set, the function returns the empty sequence. If the input is the empty sequence, the function returns the empty sequence. *

* Provides a client interface to the math:mode server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:anyAtomicType server data type */ public ServerExpression mode(ServerExpression arg, String options); /** * Returns the mode of a sequence. The mode is the value that occurs most frequently in a data set. If no value occurs more than once in the data set, the function returns the empty sequence. If the input is the empty sequence, the function returns the empty sequence. *

* Provides a client interface to the math:mode server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:anyAtomicType server data type */ public ServerExpression mode(ServerExpression arg, ServerExpression options); /** * Returns x broken up into fraction and integer. x = fraction+integer. * * *

* Provides a client interface to the math:modf server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression modf(ServerExpression x); /** * Returns the rank of a value in a data set as a percentage of the data set. If the given value is not equal to any item in the sequence, the function returns the empty sequence. See math:rank. *

* Provides a client interface to the math:percent-rank server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param value The value to be "ranked". (of xs:anyAtomicType) * @return a server expression with the xs:double server data type */ public ServerExpression percentRank(ServerExpression arg, String value); /** * Returns the rank of a value in a data set as a percentage of the data set. If the given value is not equal to any item in the sequence, the function returns the empty sequence. See math:rank. * * *

* Provides a client interface to the math:percent-rank server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param value The value to be "ranked". (of xs:anyAtomicType) * @return a server expression with the xs:double server data type */ public ServerExpression percentRank(ServerExpression arg, ServerExpression value); /** * Returns the rank of a value in a data set as a percentage of the data set. If the given value is not equal to any item in the sequence, the function returns the empty sequence. See math:rank. *

* Provides a client interface to the math:percent-rank server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param value The value to be "ranked". (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "ascending"(default) Rank the value as if the sequence was sorted in ascending order. "descending" Rank the value as if the sequence was sorted in descending order. "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:double server data type */ public ServerExpression percentRank(ServerExpression arg, String value, String options); /** * Returns the rank of a value in a data set as a percentage of the data set. If the given value is not equal to any item in the sequence, the function returns the empty sequence. See math:rank. *

* Provides a client interface to the math:percent-rank server function. * @param arg The sequence of values. (of xs:anyAtomicType) * @param value The value to be "ranked". (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "ascending"(default) Rank the value as if the sequence was sorted in ascending order. "descending" Rank the value as if the sequence was sorted in descending order. "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:double server data type */ public ServerExpression percentRank(ServerExpression arg, ServerExpression value, ServerExpression options); /** * Returns a sequence of percentile(s) given a sequence of percentage(s). The function returns the empty sequence if either arg or p is the empty sequence. *

* Provides a client interface to the math:percentile server function. * @param arg The sequence of values to calculate the percentile(s) on. (of xs:double) * @param p The sequence of percentage(s). (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression percentile(ServerExpression arg, double p); /** * Returns a sequence of percentile(s) given a sequence of percentage(s). The function returns the empty sequence if either arg or p is the empty sequence. * * *

* Provides a client interface to the math:percentile server function. * @param arg The sequence of values to calculate the percentile(s) on. (of xs:double) * @param p The sequence of percentage(s). (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression percentile(ServerExpression arg, ServerExpression p); /** * Returns the value of pi. * * *

* Provides a client interface to the math:pi server function. * @return a server expression with the xs:double server data type */ public ServerExpression pi(); /** * Returns x^y. *

* Provides a client interface to the math:pow server function. * @param x The floating-point base number. (of xs:double) * @param y The exponent to be applied to x. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression pow(ServerExpression x, double y); /** * Returns x^y. * * *

* Provides a client interface to the math:pow server function. * @param x The floating-point base number. (of xs:double) * @param y The exponent to be applied to x. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression pow(ServerExpression x, ServerExpression y); /** * Returns numeric expression converted from degrees to radians. * * *

* Provides a client interface to the math:radians server function. * @param x An angle expressed in degrees. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression radians(ServerExpression x); /** * Returns the rank of a value in a data set. Ranks are skipped in the event of ties. If the given value is not equal to any item in the sequence, the function returns the empty sequence. The function can be used on numeric values, xs:yearMonthDuration, xs:dayTimeDuration, xs:string, xs:anyURI, xs:date, xs:dateTime, xs:time, and cts:point. *

* Provides a client interface to the math:rank server function. * @param arg1 The sequence of values. (of xs:anyAtomicType) * @param arg2 The value to be "ranked". (of xs:anyAtomicType) * @return a server expression with the xs:integer server data type */ public ServerExpression rank(ServerExpression arg1, String arg2); /** * Returns the rank of a value in a data set. Ranks are skipped in the event of ties. If the given value is not equal to any item in the sequence, the function returns the empty sequence. The function can be used on numeric values, xs:yearMonthDuration, xs:dayTimeDuration, xs:string, xs:anyURI, xs:date, xs:dateTime, xs:time, and cts:point. * * *

* Provides a client interface to the math:rank server function. * @param arg1 The sequence of values. (of xs:anyAtomicType) * @param arg2 The value to be "ranked". (of xs:anyAtomicType) * @return a server expression with the xs:integer server data type */ public ServerExpression rank(ServerExpression arg1, ServerExpression arg2); /** * Returns the rank of a value in a data set. Ranks are skipped in the event of ties. If the given value is not equal to any item in the sequence, the function returns the empty sequence. The function can be used on numeric values, xs:yearMonthDuration, xs:dayTimeDuration, xs:string, xs:anyURI, xs:date, xs:dateTime, xs:time, and cts:point. *

* Provides a client interface to the math:rank server function. * @param arg1 The sequence of values. (of xs:anyAtomicType) * @param arg2 The value to be "ranked". (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "ascending"(default) Rank the value as if the sequence was sorted in ascending order. "descending" Rank the value as if the sequence was sorted in descending order. "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:integer server data type */ public ServerExpression rank(ServerExpression arg1, String arg2, String options); /** * Returns the rank of a value in a data set. Ranks are skipped in the event of ties. If the given value is not equal to any item in the sequence, the function returns the empty sequence. The function can be used on numeric values, xs:yearMonthDuration, xs:dayTimeDuration, xs:string, xs:anyURI, xs:date, xs:dateTime, xs:time, and cts:point. *

* Provides a client interface to the math:rank server function. * @param arg1 The sequence of values. (of xs:anyAtomicType) * @param arg2 The value to be "ranked". (of xs:anyAtomicType) * @param options Options. The default is (). Options include: "ascending"(default) Rank the value as if the sequence was sorted in ascending order. "descending" Rank the value as if the sequence was sorted in descending order. "collation=URI" Applies only when $arg is of the xs:string type. If no specified, the default collation is used. "coordinate-system=name" Applies only when $arg is of the cts:point type. If no specified, the default coordinate system is used. (of xs:string) * @return a server expression with the xs:integer server data type */ public ServerExpression rank(ServerExpression arg1, ServerExpression arg2, ServerExpression options); /** * Returns the sine of x, in the range from -1 to +1 (inclusive). * * *

* Provides a client interface to the math:sin server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression sin(ServerExpression x); /** * Returns the hyperbolic sine of x. * * *

* Provides a client interface to the math:sinh server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression sinh(ServerExpression x); /** * Returns the square root of x. * * *

* Provides a client interface to the math:sqrt server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression sqrt(ServerExpression x); /** * Returns the sample standard deviation of a sequence of values. The function returns the empty sequence if the length of the input sequence is less than 2. * * *

* Provides a client interface to the math:stddev server function. * @param arg The sequence of values. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression stddev(ServerExpression arg); /** * Returns the standard deviation of a population. The function returns the empty sequence if the input is the empty sequence. * * *

* Provides a client interface to the math:stddev-p server function. * @param arg The sequence of values. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression stddevP(ServerExpression arg); /** * Returns the tangent of x. * * *

* Provides a client interface to the math:tan server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression tan(ServerExpression x); /** * Returns the hyperbolic tangent of x, in the range from -1 to +1 (inclusive). * * *

* Provides a client interface to the math:tanh server function. * @param x The floating point number to be evaluated. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression tanh(ServerExpression x); /** * Returns the number truncated to a certain number of decimal places. If type of arg is one of the four numeric types xs:float, xs:double, xs:decimal or xs:integer the type of the result is the same as the type of arg. If the type of arg is a type derived from one of the numeric types, the result is an instance of the base numeric type. * * *

* Provides a client interface to the math:trunc server function. * @param arg A numeric value to truncate. (of xs:numeric) * @return a server expression with the xs:numeric server data type */ public ServerExpression trunc(ServerExpression arg); /** * Returns the number truncated to a certain number of decimal places. If type of arg is one of the four numeric types xs:float, xs:double, xs:decimal or xs:integer the type of the result is the same as the type of arg. If the type of arg is a type derived from one of the numeric types, the result is an instance of the base numeric type. *

* Provides a client interface to the math:trunc server function. * @param arg A numeric value to truncate. (of xs:numeric) * @param n The numbers of decimal places to truncate to. The default is 0. Negative values cause that many digits to the left of the decimal point to be truncated. (of xs:integer) * @return a server expression with the xs:numeric server data type */ public ServerExpression trunc(ServerExpression arg, long n); /** * Returns the number truncated to a certain number of decimal places. If type of arg is one of the four numeric types xs:float, xs:double, xs:decimal or xs:integer the type of the result is the same as the type of arg. If the type of arg is a type derived from one of the numeric types, the result is an instance of the base numeric type. *

* Provides a client interface to the math:trunc server function. * @param arg A numeric value to truncate. (of xs:numeric) * @param n The numbers of decimal places to truncate to. The default is 0. Negative values cause that many digits to the left of the decimal point to be truncated. (of xs:integer) * @return a server expression with the xs:numeric server data type */ public ServerExpression trunc(ServerExpression arg, ServerExpression n); /** * Returns the sample variance of a sequence of values. The function returns the empty sequence if the length of the input sequence is less than 2. * * *

* Provides a client interface to the math:variance server function. * @param arg The sequence of values. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression variance(ServerExpression arg); /** * Returns the population variance of a sequence of values. The function returns the empty sequence if the input is the empty sequence. * * *

* Provides a client interface to the math:variance-p server function. * @param arg The sequence of values. (of xs:double) * @return a server expression with the xs:double server data type */ public ServerExpression varianceP(ServerExpression arg); }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy