public abstract class LinReg extends FunDefBase
Modifier and Type | Class and Description |
---|---|
static class |
LinReg.InterceptFunDef
Definition of the
LinRegIntercept MDX function. |
static class |
LinReg.PointFunDef
Definition of the
LinRegPoint MDX function. |
static class |
LinReg.R2FunDef
Definition of the
LinRegR2 MDX function. |
static class |
LinReg.SlopeFunDef
Definition of the
LinRegSlope MDX function. |
(package private) static class |
LinReg.Value |
static class |
LinReg.VarianceFunDef
Definition of the
LinRegVariance MDX function. |
FunUtil.DescendingValueComparator, FunUtil.Flag, FunUtil.ObjIntPair<T>, FunUtil.OrderKey, FunUtil.Quicksorter<T>, FunUtil.SetWrapper, FunUtil.SortKeySpec, FunUtil.TupleExpMemoComparator
Util.AbstractFlatList<T>, Util.ByteMatcher, Util.ErrorCellValue, Util.Flat2List<T>, Util.Flat3List<T>, Util.Functor1<RT,PT>, Util.GcIterator<T>, Util.MemoryInfo, Util.PropertyList, Util.SqlNullSafeComparator
Modifier and Type | Field and Description |
---|---|
static int |
Intercept |
(package private) static Resolver |
InterceptResolver |
static int |
Point |
(package private) static Resolver |
PointResolver |
static int |
R2 |
(package private) static Resolver |
R2Resolver |
(package private) int |
regType
Code for the specific function.
|
static int |
Slope |
(package private) static Resolver |
SlopeResolver |
static int |
Variance |
(package private) static Resolver |
VarianceResolver |
flags, parameterCategories, returnCategory, signature
BooleanNull, DoubleEmpty, DoubleNull, emptyStringArray, IntegerNull, NullMember
DEBUG, EmptyValue, IBM_JVM, JdbcVersion, JVM_INSTANCE_UUID, nl, nullValue, PreJdk15, PreJdk16, Retrowoven
Modifier | Constructor and Description |
---|---|
protected |
LinReg(FunDef funDef,
int regType) |
Modifier and Type | Method and Description |
---|---|
static LinReg.Value |
accuracy(LinReg.Value value) |
Calc |
compileCall(ResolvedFunCall call,
ExpCompiler compiler)
Converts a call to this function into executable objects.
|
protected static void |
debug(String type,
String msg) |
static List |
forecast(LinReg.Value value) |
static LinReg.Value |
linearReg(List xlist,
List ylist) |
protected static LinReg.Value |
process(Evaluator evaluator,
ListCalc listCalc,
DoubleCalc yCalc,
DoubleCalc xCalc) |
castType, createCall, getDescription, getName, getParameterCategories, getResultType, getReturnCategory, getSignature, getSyntax, unparse, validateArg
addMembers, addMembers, addUnique, ancestor, appendTuple, avg, box, box, checkCompatible, checkIterListResultStyles, checkListResultStyles, compareHierarchically, compareSiblingMembers, compareValues, compareValues, correlation, count, cousin, covariance, createDummyFunDef, decodeCategory, decodeParameterCategories, decodeReturnCategory, decodeSyntacticType, equalTuple, evaluateMembers, evaluateSet, evaluateSet, evaluateTuples, getDimensionDefaultHierarchy, getLiteralArg, getLiteralArg, getNonEmptyLevelMembers, getNonEmptyMemberChildren, getNonEmptyMemberChildrenWithDetails, hierarchizeMemberList, hierarchizeTupleList, hierarchyMembers, isAncestorOf, levelMembers, makeNullMember, makeNullTuple, max, memberRange, min, newEvalException, newEvalException, newEvalException, parseMember, parseMemberList, parseTuple, parseTupleList, partiallySortMembers, partiallySortTuples, partialSort, percentile, periodsToDate, quartile, removeCalculatedMembers, removeCalculatedMembers, resolveFunArgs, sortMembers, sortMembers, sortTuples, sortTuples, stablePartialSort, stablePartialSort, stablePartialSortArray, stablePartialSortJulian, stablePartialSortMarc, stablePartialSortPedro, stdev, sum, sumDouble, sumDouble, toPercent, tupleContainsNullMember, tupleContainsNullMember, var, worthCaching
addDatabaseTime, addLevelCalculatedMembers, append, appendArrays, areOccurencesEqual, assertPostcondition, assertPostcondition, assertPrecondition, assertPrecondition, assertTrue, assertTrue, badValue, binarySearch, bitSetBetween, camelToUpper, canCast, cancelStatement, caseSensitiveCompareName, cast, cast, castToIterable, checkCJResultLimit, close, commaList, compare, compareIntegers, compareKey, compareName, compileScript, convert, convert, convertOlap4jConnectStringToNativeMondrian, convertStackToString, copyOf, copyOf, copyOf, copyOf, copyOf, createExpr, createRandom, createRootRole, createSimpleValidator, createUdf, dbTimeMillis, deprecated, deprecated, digestMd5, digestSha256, equal, equalName, equals, equals, falseFunctor, filter, flatList, flatList, flatListCopy, generateUuidString, genericArray, getAnnotation, getClosestResource, getDimensionCube, getErrorMessage, getErrorMessage, getExecutorService, getFirstDescendantOnLevel, getMatchingCause, getMemberOrdinalInParent, getMemoryInfo, getScheduledExecutorService, hash, hash, hashArray, identityFunctor, implode, intersect, isBlank, isEmpty, isNull, isSorted, isValidProperty, last, lookup, lookup, lookup, lookup, lookup, lookupCompound, lookupCompound, lookupHierarchyLevel, lookupHierarchyRootMember, lookupHierarchyRootMember, lookupProperty, makeBigDecimalFromDouble, makeFqName, makeFqName, makeFqName, matches, mdxEncodeString, needToImplement, newElementNotFoundException, newError, newError, newIdentityHashSet, newIdentityHashSetFake, newInternal, newInternal, newTimer, nonDbTimeMillis, normalizeName, only, parseCommaList, parseConnectString, parseIdentifier, parseInterval, parseLocale, printMemory, printMemory, quoteForMdx, quoteForMdx, quoteJavaString, quoteMdxIdentifier, quoteMdxIdentifier, quoteMdxIdentifier, quoteMdxIdentifier, quotePattern, readFully, readFully, readURL, readURL, readURL, readVirtualFile, readVirtualFileAsString, replace, replace, replaceProperties, safeGet, singleQuoteString, singleQuoteString, sort, sort, threadLocalRemove, toMap, toNullValuesMap, toOlap4j, toOlap4j, toOlap4j, toURL, trueFunctor, unexpected, uniquify, unparse, unparse, wildcardToRegexp
addChild, addChild, addChildren, addElement, concatenate, createDefaultParser, discard, discard, discard, discard, discard, discard, discard, discard, discard, getFirstInstance, wrapperToXml
getFirstTagName, printAtt, printAtt, printAtt, printAtt, printPCDATA, printPCDATA, printPCDATA, quoteAtt, quoteAtt, quoteAtt, quoteAtt, quotePCDATA, stringEncodeXML, stringHasXMLSpecials
final int regType
public static final int Point
public static final int R2
public static final int Intercept
public static final int Slope
public static final int Variance
static final Resolver InterceptResolver
static final Resolver PointResolver
static final Resolver SlopeResolver
static final Resolver R2Resolver
static final Resolver VarianceResolver
public Calc compileCall(ResolvedFunCall call, ExpCompiler compiler)
FunDef
The result must implement the appropriate interface for the result
type. For example, a function which returns an integer must return
an object which implements IntegerCalc
.
compileCall
in interface FunDef
compileCall
in class FunDefBase
protected static LinReg.Value process(Evaluator evaluator, ListCalc listCalc, DoubleCalc yCalc, DoubleCalc xCalc)
public static LinReg.Value accuracy(LinReg.Value value)
public static LinReg.Value linearReg(List xlist, List ylist)
public static List forecast(LinReg.Value value)