(* Content-type: application/vnd.wolfram.mathematica *) (*** Wolfram Notebook File ***) (* http://www.wolfram.com/nb *) (* CreatedBy='Mathematica 13.1' *) (*CacheID: 234*) (* Internal cache information: NotebookFileLineBreakTest NotebookFileLineBreakTest NotebookDataPosition[ 158, 7] NotebookDataLength[ 1567736, 30774] NotebookOptionsPosition[ 1388618, 27348] NotebookOutlinePosition[ 1530876, 30016] CellTagsIndexPosition[ 1528975, 29966] WindowTitle->QuantileRegression | Definition Notebook WindowFrame->Normal*) (* Beginning of Notebook Content *) Notebook[{ Cell[CellGroupData[{ Cell["QuantileRegression", "Title", CellTags->{"Name", "TemplateCell", "Title"}, CellID->848432426], Cell["\<\ Computes quantile regression fits over a time series, a list of numbers or a \ list of numeric pairs\ \>", "Text", CellTags->{"Description", "TemplateCell"}, CellID->904292002], Cell[CellGroupData[{ Cell[TextData[{ "Definition", Cell[BoxData[ PaneSelectorBox[{True-> TemplateBox[{"Function", Cell[ BoxData[ FrameBox[ Cell[ "Define your function using the name you gave in the Title line \ above. You can add input cells and extra code to define additional input \ cases or prerequisites. All definitions, including dependencies, will be \ included in the generated resource function.\n\nThis section should be \ evaluated before creating the Examples section below.", "MoreInfoText"], Background -> GrayLevel[0.95], FrameMargins -> 20, FrameStyle -> GrayLevel[0.9], RoundingRadius -> 5, ImageSize -> { Scaled[0.65], Automatic}]], "MoreInfoText", Deletable -> True, CellTags -> {"SectionMoreInfoFunction"}, CellMargins -> {{66, 66}, {15, 15}}]}, "MoreInfoOpenerButtonTemplate"]}, Dynamic[ CurrentValue[ EvaluationNotebook[], {TaggingRules, "ResourceCreateNotebook"}]], ImageSize->Automatic]]] }], "Section", Editable->False, Deletable->False, TaggingRules->{"TemplateGroupName" -> "Function"}, DefaultNewCellStyle->"Input", CellTags->{"Definition", "Function", "TemplateCellGroup"}, CellID->72845326], Cell[BoxData[{ RowBox[{ RowBox[{ RowBox[{"Clear", "[", "QuantileRegression", "]"}], ";"}], "\[IndentingNewLine]"}], "\n", RowBox[{ RowBox[{ RowBox[{ RowBox[{"SyntaxInformation", "[", "QuantileRegression", "]"}], "=", RowBox[{"{", RowBox[{"\"\\"", "\[Rule]", RowBox[{"{", RowBox[{"_.", ",", "_", ",", "_", ",", RowBox[{"OptionsPattern", "[", "]"}]}], "}"}]}], "}"}]}], ";"}], "\[IndentingNewLine]"}], "\n", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], "=", "\"\\""}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"Options", "[", "QuantileRegression", "]"}], "=", RowBox[{"{", RowBox[{ RowBox[{"InterpolationOrder", "\[Rule]", "3"}], ",", RowBox[{"Method", "\[Rule]", "LinearProgramming"}]}], "}"}]}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "[", RowBox[{ RowBox[{"data_", "?", "VectorQ"}], ",", "knots_", ",", "probs_", ",", RowBox[{"opts", ":", RowBox[{"OptionsPattern", "[", "]"}]}]}], "]"}], ":=", RowBox[{"QuantileRegression", "[", RowBox[{ RowBox[{"Transpose", "[", RowBox[{"{", RowBox[{ RowBox[{"Range", "[", RowBox[{"Length", "[", "data", "]"}], "]"}], ",", "data"}], "}"}], "]"}], ",", "knots", ",", "probs", ",", "opts"}], "]"}]}], ";"}], "\[IndentingNewLine]"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "[", RowBox[{ RowBox[{"data", ":", RowBox[{"(", RowBox[{"_TimeSeries", "|", "_TemporalData"}], ")"}]}], ",", "knots_", ",", "probs_", ",", RowBox[{"opts", ":", RowBox[{"OptionsPattern", "[", "]"}]}]}], "]"}], ":=", "\[IndentingNewLine]", RowBox[{"QuantileRegression", "[", RowBox[{ RowBox[{"QuantityMagnitude", "[", RowBox[{"data", "[", "\"\\"", "]"}], "]"}], ",", "knots", ",", "probs", ",", "opts"}], "]"}]}], ";"}], "\[IndentingNewLine]"}], "\n", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "[", RowBox[{"data_", ",", "knots_", ",", "probsArg_", ",", RowBox[{"opts", ":", RowBox[{"OptionsPattern", "[", "]"}]}]}], "]"}], ":=", "\[IndentingNewLine]", RowBox[{"Block", "[", RowBox[{ RowBox[{"{", RowBox[{"mOptVal", ",", "intOrdOptVal", ",", RowBox[{"probs", "=", RowBox[{"Flatten", "@", RowBox[{"List", "@", "probsArg"}]}]}]}], "}"}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{ RowBox[{"Which", "[", "\[IndentingNewLine]", RowBox[{ RowBox[{"!", RowBox[{"(", RowBox[{ RowBox[{"MatrixQ", "[", RowBox[{"data", ",", "NumericQ"}], "]"}], "&&", RowBox[{ RowBox[{ RowBox[{"Dimensions", "[", "data", "]"}], "[", RowBox[{"[", "2", "]"}], "]"}], "\[GreaterEqual]", "2"}]}], ")"}]}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"!", RowBox[{"(", RowBox[{ RowBox[{ RowBox[{"IntegerQ", "[", "knots", "]"}], "&&", RowBox[{"knots", ">", "0"}]}], "||", RowBox[{"VectorQ", "[", RowBox[{"knots", ",", "NumericQ"}], "]"}]}], ")"}]}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"!", RowBox[{"VectorQ", "[", RowBox[{"probs", ",", RowBox[{ RowBox[{ RowBox[{"NumericQ", "[", "#", "]"}], "&&", RowBox[{"0", "\[LessEqual]", "#", "\[LessEqual]", "1"}]}], "&"}]}], "]"}]}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}]}], "\[IndentingNewLine]", "]"}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"mOptVal", "=", RowBox[{"OptionValue", "[", RowBox[{"QuantileRegression", ",", "Method"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"intOrdOptVal", "=", RowBox[{"OptionValue", "[", RowBox[{"QuantileRegression", ",", "InterpolationOrder"}], "]"}]}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"Which", "[", "\[IndentingNewLine]", RowBox[{ RowBox[{"!", RowBox[{"(", RowBox[{ RowBox[{"IntegerQ", "[", "intOrdOptVal", "]"}], "&&", RowBox[{"intOrdOptVal", "\[GreaterEqual]", "0"}]}], ")"}]}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"TrueQ", "[", RowBox[{"mOptVal", "===", "LinearProgramming"}], "]"}], ",", "\[IndentingNewLine]", RowBox[{"LPSplineQuantileRegression", "[", RowBox[{"data", ",", "knots", ",", "intOrdOptVal", ",", "probs"}], "]"}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{ RowBox[{"ListQ", "[", "mOptVal", "]"}], "&&", RowBox[{"TrueQ", "[", RowBox[{ RowBox[{"mOptVal", "[", RowBox[{"[", "1", "]"}], "]"}], "===", "LinearProgramming"}], "]"}]}], ",", "\[IndentingNewLine]", RowBox[{"LPSplineQuantileRegression", "[", RowBox[{ "data", ",", "knots", ",", "intOrdOptVal", ",", "probs", ",", RowBox[{"Rest", "[", "mOptVal", "]"}]}], "]"}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", "True", ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}]}], "\[IndentingNewLine]", "]"}]}]}], "\[IndentingNewLine]", "]"}]}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"QuantileRegression", "[", "___", "]"}], ":=", RowBox[{"Block", "[", RowBox[{ RowBox[{"{", "}"}], ",", RowBox[{ RowBox[{"Message", "[", RowBox[{"QuantileRegression", "::", "\"\\""}], "]"}], ";", "\[IndentingNewLine]", RowBox[{"{", "}"}]}]}], "]"}]}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"Clear", "[", "LPSplineQuantileRegression", "]"}], ";"}], "\n"}], "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{ RowBox[{"LPSplineQuantileRegression", "[", RowBox[{ RowBox[{"data_", "?", "MatrixQ"}], ",", "npieces_Integer", ",", "order_Integer", ",", RowBox[{"probs", ":", RowBox[{"{", RowBox[{ RowBox[{"_", "?", "NumberQ"}], ".."}], "}"}]}], ",", RowBox[{"opts", ":", RowBox[{"OptionsPattern", "[", "]"}]}]}], "]"}], ":=", RowBox[{"LPSplineQuantileRegression", "[", RowBox[{"data", ",", RowBox[{"Rescale", "[", RowBox[{ RowBox[{"Range", "[", RowBox[{"0", ",", "1", ",", RowBox[{"1", "/", "npieces"}]}], "]"}], ",", RowBox[{"{", RowBox[{"0", ",", "1"}], "}"}], ",", RowBox[{"{", RowBox[{ RowBox[{"Min", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "1"}], "]"}], "]"}], "]"}], ",", RowBox[{"Max", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "1"}], "]"}], "]"}], "]"}]}], "}"}]}], "]"}], ",", "order", ",", "probs", ",", "opts"}], "]"}]}], ";"}], "\[IndentingNewLine]"}], "\n", RowBox[{ RowBox[{ RowBox[{"LPSplineQuantileRegression", "[", RowBox[{ RowBox[{"dataArg_", "?", "MatrixQ"}], ",", RowBox[{"knotsArg", ":", RowBox[{"{", RowBox[{ RowBox[{"_", "?", "NumberQ"}], ".."}], "}"}]}], ",", "order_Integer", ",", RowBox[{"probs", ":", RowBox[{"{", RowBox[{ RowBox[{"_", "?", "NumberQ"}], ".."}], "}"}]}], ",", RowBox[{"opts", ":", RowBox[{"OptionsPattern", "[", "]"}]}]}], "]"}], ":=", RowBox[{"Block", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"data", "=", "dataArg"}], ",", RowBox[{"knots", "=", RowBox[{"Sort", "[", "knotsArg", "]"}]}], ",", RowBox[{"yMedian", "=", "0"}], ",", RowBox[{"yFactor", "=", "1"}], ",", RowBox[{"yShift", "=", "0"}], ",", RowBox[{"n", "=", RowBox[{ RowBox[{"Dimensions", "[", "dataArg", "]"}], "[", RowBox[{"[", "1", "]"}], "]"}]}], ",", "pfuncs", ",", "c", ",", "t", ",", "qrSolutions", ",", "mat"}], "}"}], ",", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{ RowBox[{"If", "[", RowBox[{ RowBox[{ RowBox[{"Min", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "]"}], "<", "0"}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"yMedian", "=", RowBox[{"Median", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"yFactor", "=", RowBox[{"InterquartileRange", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{ RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "=", RowBox[{"Standardize", "[", RowBox[{ RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], ",", "Median", ",", "InterquartileRange"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"yShift", "=", RowBox[{"Abs", "[", RowBox[{"Min", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "]"}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{ RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "=", RowBox[{ RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], "+", "yShift"}]}], ";"}]}], "\[IndentingNewLine]", "]"}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"(*", RowBox[{ "Enhance", " ", "the", " ", "knots", " ", "list", " ", "with", " ", "additional", " ", "clamped", " ", RowBox[{"knots", "."}]}], "*)"}], "\[IndentingNewLine]", RowBox[{"knots", "=", RowBox[{"Join", "[", RowBox[{ RowBox[{"Table", "[", RowBox[{ RowBox[{"Min", "[", "knots", "]"}], ",", RowBox[{"{", "order", "}"}]}], "]"}], ",", "knots", ",", RowBox[{"Table", "[", RowBox[{ RowBox[{"Max", "[", "knots", "]"}], ",", RowBox[{"{", "order", "}"}]}], "]"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"If", "[", RowBox[{ RowBox[{ RowBox[{ RowBox[{"Length", "[", "knots", "]"}], "-", "order", "-", "2"}], "<", "0"}], ",", RowBox[{ RowBox[{"Message", "[", RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], ",", "knots", ",", "order"}], "]"}], ";", "\[IndentingNewLine]", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}]}], "\[IndentingNewLine]", "]"}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"(*", RowBox[{"B", "-", RowBox[{"spline", " ", "basis", " ", "expressions"}]}], "*)"}], "\[IndentingNewLine]", RowBox[{"pfuncs", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"PiecewiseExpand", "[", RowBox[{"BSplineBasis", "[", RowBox[{ RowBox[{"{", RowBox[{"order", ",", "knots"}], "}"}], ",", "i", ",", "t"}], "]"}], "]"}], ",", RowBox[{"{", RowBox[{"i", ",", "0", ",", RowBox[{ RowBox[{"Length", "[", "knots", "]"}], "-", "order", "-", "2"}]}], "}"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"If", "[", RowBox[{ RowBox[{"VectorQ", "[", RowBox[{"pfuncs", ",", RowBox[{ RowBox[{"#", "\[Equal]", "0"}], "&"}]}], "]"}], ",", "\[IndentingNewLine]", RowBox[{ RowBox[{"Message", "[", RowBox[{ RowBox[{"QuantileRegression", "::", "\"\\""}], ",", "knots", ",", "order"}], "]"}], ";", "\[IndentingNewLine]", RowBox[{"Return", "[", RowBox[{"{", "}"}], "]"}]}]}], "\[IndentingNewLine]", "]"}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"(*", RowBox[{"B", "-", RowBox[{"spline", " ", "basis", " ", "functions"}]}], "*)"}], "\[IndentingNewLine]", RowBox[{"pfuncs", "=", RowBox[{ RowBox[{"Function", "[", RowBox[{ RowBox[{"{", "f", "}"}], ",", RowBox[{"With", "[", RowBox[{ RowBox[{"{", RowBox[{"bf", "=", RowBox[{"f", "/.", RowBox[{"t", "\[Rule]", "#"}]}]}], "}"}], ",", RowBox[{"bf", "&"}]}], "]"}]}], "]"}], "/@", "pfuncs"}]}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"(*", RowBox[{"Create", " ", "the", " ", "conditions", " ", "matrix"}], "*)"}], "\[IndentingNewLine]", RowBox[{"mat", "=", RowBox[{"Table", "[", RowBox[{ RowBox[{"Join", "[", RowBox[{"Through", "[", RowBox[{"pfuncs", "[", RowBox[{"data", "[", RowBox[{"[", RowBox[{"i", ",", "1"}], "]"}], "]"}], "]"}], "]"}], "]"}], ",", RowBox[{"{", RowBox[{"i", ",", "1", ",", "n"}], "}"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"mat", "=", RowBox[{"MapThread", "[", RowBox[{"Join", ",", RowBox[{"{", RowBox[{"mat", ",", RowBox[{"IdentityMatrix", "[", "n", "]"}], ",", RowBox[{"-", RowBox[{"IdentityMatrix", "[", "n", "]"}]}]}], "}"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"mat", "=", RowBox[{"SparseArray", "[", "mat", "]"}]}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"(*", RowBox[{"Find", " ", "the", " ", "regression", " ", "quantiles"}], "*)"}], "\[IndentingNewLine]", RowBox[{"qrSolutions", "=", "\[IndentingNewLine]", RowBox[{"Table", "[", "\[IndentingNewLine]", RowBox[{ RowBox[{ RowBox[{"c", "=", RowBox[{"Join", "[", RowBox[{ RowBox[{"ConstantArray", "[", RowBox[{"0", ",", RowBox[{"Length", "[", "pfuncs", "]"}]}], "]"}], ",", RowBox[{ RowBox[{"ConstantArray", "[", RowBox[{"1", ",", "n"}], "]"}], " ", "q"}], ",", RowBox[{ RowBox[{"ConstantArray", "[", RowBox[{"1", ",", "n"}], "]"}], " ", RowBox[{"(", RowBox[{"1", "-", "q"}], ")"}]}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"t", "=", RowBox[{"LinearProgramming", "[", RowBox[{"c", ",", "mat", ",", RowBox[{"Transpose", "[", RowBox[{"{", RowBox[{ RowBox[{"data", "[", RowBox[{"[", RowBox[{"All", ",", "2"}], "]"}], "]"}], ",", RowBox[{"ConstantArray", "[", RowBox[{"0", ",", "n"}], "]"}]}], "}"}], "]"}], ",", RowBox[{"DeleteCases", "[", RowBox[{ RowBox[{"{", "opts", "}"}], ",", RowBox[{"InterpolationOrder", "\[Rule]", "_"}]}], "]"}]}], "]"}]}], ";", "\[IndentingNewLine]", RowBox[{"If", "[", RowBox[{ RowBox[{"!", RowBox[{"(", RowBox[{ RowBox[{"VectorQ", "[", RowBox[{"t", ",", "NumberQ"}], "]"}], "&&", RowBox[{ RowBox[{"Length", "[", "t", "]"}], ">", RowBox[{"Length", "[", "pfuncs", "]"}]}]}], ")"}]}], ",", RowBox[{"ConstantArray", "[", RowBox[{"0", ",", RowBox[{"Length", "[", "pfuncs", "]"}]}], "]"}], ",", "t"}], "]"}]}], ",", "\[IndentingNewLine]", RowBox[{"{", RowBox[{"q", ",", "probs"}], "}"}]}], "]"}]}], ";", "\[IndentingNewLine]", "\[IndentingNewLine]", RowBox[{"If", "[", RowBox[{ RowBox[{ RowBox[{"yMedian", "\[Equal]", "0"}], "&&", RowBox[{"yFactor", "\[Equal]", "1"}]}], ",", "\[IndentingNewLine]", RowBox[{"Table", "[", RowBox[{ RowBox[{"With", "[", RowBox[{ RowBox[{"{", RowBox[{"f", "=", RowBox[{ RowBox[{"pfuncs", "[", RowBox[{"[", RowBox[{"All", ",", "1"}], "]"}], "]"}], ".", RowBox[{"qrSolutions", "[", RowBox[{"[", RowBox[{"i", ",", RowBox[{"1", ";;", RowBox[{"Length", "[", "pfuncs", "]"}]}]}], "]"}], "]"}]}]}], "}"}], ",", RowBox[{"f", "&"}]}], "]"}], ",", RowBox[{"{", RowBox[{"i", ",", "1", ",", RowBox[{"Length", "[", "probs", "]"}]}], "}"}]}], "]"}], ",", "\[IndentingNewLine]", RowBox[{"(*", "ELSE", "*)"}], "\[IndentingNewLine]", RowBox[{"Map", "[", RowBox[{ RowBox[{"Function", "[", RowBox[{ RowBox[{"{", "ws", "}"}], ",", RowBox[{"With", "[", RowBox[{ RowBox[{"{", RowBox[{"f", "=", RowBox[{ RowBox[{"yFactor", " ", RowBox[{"(", RowBox[{ RowBox[{"(", RowBox[{ RowBox[{"pfuncs", "[", RowBox[{"[", RowBox[{"All", ",", "1"}], "]"}], "]"}], ".", "ws"}], ")"}], "-", "yShift"}], ")"}]}], "+", "yMedian"}]}], "}"}], ",", RowBox[{"f", "&"}]}], "]"}]}], "]"}], ",", RowBox[{"qrSolutions", "[", RowBox[{"[", RowBox[{"All", ",", RowBox[{"1", ";;", RowBox[{"Length", "[", "pfuncs", "]"}]}]}], "]"}], "]"}]}], "]"}]}], "\[IndentingNewLine]", "]"}]}]}], "\[IndentingNewLine]", "]"}]}], ";"}]}], "Input", CellChangeTimes->{{3.780090111142228*^9, 3.780090111143919*^9}, { 3.78009151043077*^9, 3.780091545673334*^9}, {3.7800917846228313`*^9, 3.780091817778371*^9}, {3.78009288520485*^9, 3.7800929469107933`*^9}, { 3.780093067495591*^9, 3.7800930944217567`*^9}, {3.780099877005951*^9, 3.780099957007475*^9}, {3.780125414908991*^9, 3.780125453520102*^9}, { 3.780126810643395*^9, 3.780126817674762*^9}, {3.780126948169297*^9, 3.780126949453906*^9}, {3.780127181683876*^9, 3.780127183671414*^9}, { 3.780128265893415*^9, 3.7801282667803907`*^9}, {3.78014584312819*^9, 3.780145860012772*^9}}, CellLabel->"In[1]:=", CellID->649765581] }, Open ]], Cell[CellGroupData[{ Cell["Documentation", "Section", Editable->False, Deletable->False, TaggingRules->{"TemplateGroupName" -> "Documentation"}, CellTags->{"Documentation", "TemplateSection"}, CellID->429741307], Cell[CellGroupData[{ Cell[TextData[{ "Usage", Cell[BoxData[ PaneSelectorBox[{True-> TemplateBox[{"Usage", Cell[ BoxData[ FrameBox[ Cell[ TextData[{ "Document input usage cases by first typing an input structure, \ then pressing ", Cell[ BoxData[ StyleBox[ DynamicBox[ ToBoxes[ If[$OperatingSystem === "MacOSX", "\[ReturnKey]", "\[EnterKey]"], StandardForm], SingleEvaluation -> True, Evaluator -> "System"], ShowStringCharacters -> False]]], " to add a brief explanation of the function\[CloseCurlyQuote]s \ behavior for that structure. Pressing ", Cell[ BoxData[ StyleBox[ DynamicBox[ ToBoxes[ If[$OperatingSystem === "MacOSX", "\[ReturnKey]", "\[EnterKey]"], StandardForm], SingleEvaluation -> True, Evaluator -> "System"], ShowStringCharacters -> False]]], " repeatedly will create new cases as needed. Every input usage \ case defined above should be demonstrated explicitly here.\n\nSee existing \ documentation pages for examples."}], "MoreInfoText"], Background -> GrayLevel[0.95], FrameMargins -> 20, FrameStyle -> GrayLevel[0.9], RoundingRadius -> 5, ImageSize -> { Scaled[0.65], Automatic}]], "MoreInfoText", Deletable -> True, CellTags -> {"SectionMoreInfoUsage"}, CellMargins -> {{66, 66}, {15, 15}}]}, "MoreInfoOpenerButtonTemplate"]}, Dynamic[ CurrentValue[ EvaluationNotebook[], {TaggingRules, "ResourceCreateNotebook"}]], ImageSize->Automatic]]] }], "Subsection", Editable->False, Deletable->False, TaggingRules->{"TemplateGroupName" -> "Usage"}, DefaultNewCellStyle->{"UsageInputs", FontFamily -> "Source Sans Pro"}, CellTags->{"TemplateCellGroup", "Usage"}, CellID->542419310], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"QuantileRegression", "[", RowBox[{ StyleBox["data", "TI"], ",", StyleBox["knots", "TI"], ",", StyleBox["probs", "TI"]}], "]"}]], "UsageInputs", FontFamily->"Source Sans Pro", CellID->65901697], Cell[TextData[{ "does quantile regression over the times series or data array ", StyleBox["data", "TI"], " using the knots specification ", StyleBox["knots", "TI"], " for the probabilties ", StyleBox["probs", "TI"], "." }], "UsageDescription", CellID->109501781] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"QuantileRegression", "[", RowBox[{ StyleBox["data", "TI"], ",", StyleBox["knots", "TI"], ",", StyleBox["probs", "TI"], ",", StyleBox["opts", "TI"]}], "]"}]], "UsageInputs", FontFamily->"Source Sans Pro", CellID->939780070], Cell[TextData[{ "does quantile regression with the options ", StyleBox["opts", "TI"], "." }], "UsageDescription", CellID->806208417] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell[TextData[{ "Details & Options", Cell[BoxData[ PaneSelectorBox[{True-> TemplateBox[{"Notes", Cell[ BoxData[ FrameBox[ Cell[ "Give a detailed explanation of how the function is used and \ configured (e.g. acceptable input types, result formats, options \ specifications, background information). This section may include multiple \ cells, bullet lists, tables, hyperlinks and additional styles/structures as \ needed.\n\nAdd any other information that may be relevant, such as when the \ function was first discovered or how and why it is used within a given field. \ Include all relevant background or contextual information related to the \ function, its development, and its usage.", "MoreInfoText"], Background -> GrayLevel[0.95], FrameMargins -> 20, FrameStyle -> GrayLevel[0.9], RoundingRadius -> 5, ImageSize -> { Scaled[0.65], Automatic}]], "MoreInfoText", Deletable -> True, CellTags -> {"SectionMoreInfoNotes"}, CellMargins -> {{66, 66}, {15, 15}}]}, "MoreInfoOpenerButtonTemplate"]}, Dynamic[ CurrentValue[ EvaluationNotebook[], {TaggingRules, "ResourceCreateNotebook"}]], ImageSize->Automatic]]] }], "Subsection", Editable->False, Deletable->False, TaggingRules->{"TemplateGroupName" -> "Notes"}, DefaultNewCellStyle->"Notes", CellTags->{"Details & Options", "Notes", "TemplateCellGroup"}, CellID->908801236], Cell[TextData[{ Cell[BoxData["QuantileRegression"], "InlineFormula", FontFamily->"Source Sans Pro"], StyleBox[" works on time series, lists of numbers and lists of numeric \ pairs.", "Text"] }], "Notes", CellID->888392426], Cell["\<\ The curves computed with quantile regression are called regression quantiles.\ \ \>", "Notes", CellTags->"TabNext", CellID->826267240], Cell[TextData[StyleBox["The regression quantiles corresponding to the \ specified probabilities are linear combinations of B-splines generated over \ the specified knots.", "Text"]], "Notes", CellID->325846065], Cell[TextData[{ StyleBox["In other words, ", "Text"], Cell[BoxData["QuantileRegression"], "InlineFormula", FontFamily->"Source Sans Pro"], StyleBox[" computes fits using a B-spline functions basis. The basis is \ specified with the knots argument and the option ", "Text"], ButtonBox["InterpolationOrder", BaseStyle->"Link", ButtonData->"paclet:ref/InterpolationOrder"], StyleBox[".", "Text"] }], "Notes", CellID->373369360], Cell[TextData[{ Cell[BoxData["QuantileRegression"], "InlineFormula", FontFamily->"Source Sans Pro"], StyleBox[" takes the following options:", "Text"] }], "Notes", CellID->680750964], Cell[BoxData[GridBox[{ {Cell[TextData[Cell[BoxData[ TagBox[ ButtonBox[ StyleBox["InterpolationOrder", "SymbolsRefLink", ShowStringCharacters->True, FontFamily->"Source Sans Pro"], BaseStyle->Dynamic[ FEPrivate`If[ CurrentValue["MouseOver"], { "Link", FontColor -> RGBColor[0.854902, 0.396078, 0.145098]}, { "Link"}]], ButtonData->"paclet:ref/InterpolationOrder", ContentPadding->False], MouseAppearanceTag["LinkHand"]]], "InlineFormula", FontFamily->"Source Sans Pro"]], "TableText"], Cell["3", "TableText"], Cell["interpolation order", "TableText"]}, {Cell[TextData[Cell[BoxData[ TagBox[ ButtonBox[ StyleBox["Method", "SymbolsRefLink", ShowStringCharacters->True, FontFamily->"Source Sans Pro"], BaseStyle->Dynamic[ FEPrivate`If[ CurrentValue["MouseOver"], { "Link", FontColor -> RGBColor[0.854902, 0.396078, 0.145098]}, { "Link"}]], ButtonData->"paclet:ref/Method", ContentPadding->False], MouseAppearanceTag["LinkHand"]]], "InlineFormula", FontFamily->"Source Sans Pro"]], "TableText"], Cell[TextData[Cell[BoxData[ TagBox[ ButtonBox[ StyleBox["LinearProgramming", "SymbolsRefLink", ShowStringCharacters->True, FontFamily->"Source Sans Pro"], BaseStyle->Dynamic[ FEPrivate`If[ CurrentValue["MouseOver"], { "Link", FontColor -> RGBColor[0.854902, 0.396078, 0.145098]}, { "Link"}]], ButtonData->"paclet:ref/LinearProgramming", ContentPadding->False], MouseAppearanceTag["LinkHand"]]], "InlineFormula", FontFamily->"Source Sans Pro"]], "TableText"], Cell[ "method for the quantile regression computations", "TableText"]} }]], "TableNotes", CellID->117795368] }, Open ]] }, Open ]], Cell[CellGroupData[{ Cell[TextData[{ "Examples", Cell[BoxData[ PaneSelectorBox[{True-> TemplateBox[{"Examples", Cell[ BoxData[ FrameBox[ Cell[ TextData[{ "Demonstrate the function\[CloseCurlyQuote]s usage, starting with \ the most basic use case and describing each example in a preceding text cell.\ \n\nWithin a group, individual examples can be delimited by inserting page \ breaks between them (either using ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"[Right-click]\"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontColor -> GrayLevel[0.286275], FontSize -> 14, StripOnInput -> False], StyleBox[ "\" \[FilledRightTriangle] \"", FontFamily -> "Source Sans Pro", FontSize -> 13.86, FontColor -> GrayLevel[0.5], StripOnInput -> False], StyleBox[ "\"Insert Page Break\"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontColor -> GrayLevel[0.286275], FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], " between cells or through the menu using ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"Insert\"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontColor -> GrayLevel[0.286275], FontSize -> 14, StripOnInput -> False], StyleBox[ "\" \[FilledRightTriangle] \"", FontFamily -> "Source Sans Pro", FontSize -> 13.86, FontColor -> GrayLevel[0.5], StripOnInput -> False], StyleBox[ "\"Page Break\"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontColor -> GrayLevel[0.286275], FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], ").\n\nExamples should be grouped into Subsection and \ Subsubsection cells similarly to existing documentation pages. Here are some \ typical Subsection names and the types of examples they normally contain:\n \ ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Basic Examples: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "most basic function usage\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Scope: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "input and display conventions, standard computational attributes \ (e.g. threading over lists)\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Options: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "available options and parameters for the function\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Applications: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "standard industry or academic applications\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Properties and Relations: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "how the function relates to other functions\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Possible Issues: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "limitations or unexpected behavior a user might experience\n ", Cell[ BoxData[ StyleBox[ TemplateBox[{ StyleBox[ "\"\[FilledSmallSquare] \"", FontColor -> RGBColor[0.8, 0.043, 0.008], StripOnInput -> False], StyleBox[ "\"Neat Examples: \"", FontFamily -> "Source Sans Pro", FontWeight -> "SemiBold", FontSize -> 14, StripOnInput -> False]}, "RowDefault"], ShowStringCharacters -> False]]], "particularly interesting, unconventional, or otherwise unique \ usage"}], "MoreInfoText"], Background -> GrayLevel[0.95], FrameMargins -> 20, FrameStyle -> GrayLevel[0.9], RoundingRadius -> 5, ImageSize -> { Scaled[0.65], Automatic}]], "MoreInfoText", Deletable -> True, CellTags -> {"SectionMoreInfoExamples"}, CellMargins -> {{66, 66}, {15, 15}}]}, "MoreInfoOpenerButtonTemplate"]}, Dynamic[ CurrentValue[ EvaluationNotebook[], {TaggingRules, "ResourceCreateNotebook"}]], ImageSize->Automatic]]] }], "Section", Editable->False, Deletable->False, TaggingRules->{"TemplateGroupName" -> "Examples"}, CellTags->{"Examples", "TemplateCellGroup"}, CellID->530638011], Cell[CellGroupData[{ Cell["Basic Examples", "Subsection", TaggingRules->{}, CellID->904125756], Cell["Make a random signal:", "Text", TaggingRules->{}, CellChangeTimes->{{3.780092494817978*^9, 3.780092532572364*^9}, { 3.7803369045752287`*^9, 3.780336905586763*^9}}, CellID->506358618], Cell[BoxData[{ RowBox[{ RowBox[{"SeedRandom", "[", "23", "]"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"n", "=", "200"}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"randData", "=", RowBox[{"Transpose", "[", RowBox[{"{", RowBox[{ RowBox[{"Range", "[", "n", "]"}], ",", RowBox[{"RandomReal", "[", RowBox[{ RowBox[{"{", RowBox[{"0", ",", "100."}], "}"}], ",", "n"}], "]"}]}], "}"}], "]"}]}], ";"}]}], "Input", TaggingRules->{}, CellChangeTimes->{{3.780089208676652*^9, 3.78008922676582*^9}, { 3.780090124340819*^9, 3.780090184146447*^9}, {3.780090251313642*^9, 3.780090264226801*^9}, {3.780090462156766*^9, 3.7800904870769043`*^9}, { 3.7800905291105328`*^9, 3.780090570191724*^9}, {3.780090781453969*^9, 3.780090871284848*^9}, {3.780090909550682*^9, 3.780091017776836*^9}, { 3.78009109623806*^9, 3.780091181931394*^9}, {3.780091586632161*^9, 3.780091595539405*^9}, {3.780091825218638*^9, 3.780091834342745*^9}, { 3.7800922062588167`*^9, 3.780092236261367*^9}, {3.780092308759981*^9, 3.7800923333739243`*^9}, 3.780092536030077*^9, {3.7800927601137877`*^9, 3.7800927660344677`*^9}, 3.78009668665062*^9, {3.780130562119527*^9, 3.7801305648517103`*^9}}, CellLabel->"In[1]:=", CellID->540492958], Cell[TextData[{ "Compute ", Cell[BoxData["QuantileRegression"], "InlineFormula", FontFamily->"Source Sans Pro"], " with five knots for the probabilities ", Cell[BoxData[ FormBox["0.25", TraditionalForm]]], " and ", Cell[BoxData[ FormBox["0.75", TraditionalForm]]], ":" }], "Text", TaggingRules->{}, CellChangeTimes->{{3.780092537883581*^9, 3.780092577789139*^9}, { 3.780093364327034*^9, 3.780093382640505*^9}, {3.78033442892669*^9, 3.780334428926777*^9}, {3.785786754470047*^9, 3.7857867632154136`*^9}, { 3.858679973804859*^9, 3.858679976906979*^9}}, CellID->440269936], Cell[BoxData[ RowBox[{ RowBox[{"qFuncs", "=", RowBox[{"QuantileRegression", "[", RowBox[{"randData", ",", "5", ",", RowBox[{"{", RowBox[{"0.25", ",", "0.75"}], "}"}]}], "]"}]}], ";"}]], "Input", TaggingRules->{}, CellChangeTimes->{{3.780089208676652*^9, 3.78008922676582*^9}, { 3.780090124340819*^9, 3.780090184146447*^9}, {3.780090251313642*^9, 3.780090264226801*^9}, {3.780090462156766*^9, 3.7800904870769043`*^9}, { 3.7800905291105328`*^9, 3.780090570191724*^9}, {3.780090781453969*^9, 3.780090871284848*^9}, {3.780090909550682*^9, 3.780091017776836*^9}, { 3.78009109623806*^9, 3.780091181931394*^9}, {3.780091586632161*^9, 3.780091595539405*^9}, {3.780091825218638*^9, 3.780091834342745*^9}, { 3.7800922062588167`*^9, 3.780092236261367*^9}, {3.780092308759981*^9, 3.7800923333739243`*^9}, 3.780092536030077*^9, {3.780092785226672*^9, 3.780092797118091*^9}, {3.780093260127633*^9, 3.780093264107644*^9}, 3.7800966905203114`*^9, 3.7801305737202177`*^9}, CellLabel->"In[2]:=", CellID->674206780], Cell["Here are the formulas of the obtained regression quantiles:", "Text", TaggingRules->{}, CellChangeTimes->{{3.7800924753324957`*^9, 3.7800924902259483`*^9}, { 3.78033443880182*^9, 3.7803344447651453`*^9}}, CellID->191457323], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"Simplify", "/@", RowBox[{"Through", "[", RowBox[{"qFuncs", "[", "x", "]"}], "]"}]}]], "Input", TaggingRules->{}, CellChangeTimes->{{3.7800901884594316`*^9, 3.780090230734413*^9}}, CellLabel->"In[3]:=", CellID->119245800], Cell[BoxData[ RowBox[{"{", RowBox[{ TagBox[GridBox[{ {"\[Piecewise]", GridBox[{ {"0.`", RowBox[{ RowBox[{"x", ">", "200"}], "||", RowBox[{"x", "<", "1"}]}]}, { RowBox[{"3818.7847249915`", "\[VeryThinSpace]", "-", RowBox[{"70.59990387532112`", " ", "x"}], "+", RowBox[{"0.43316288196676034`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.0008757723390678317`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["801", "5"], "<", "x", "\[LessEqual]", "200"}]}, { RowBox[{"4099.0541288913655`", "\[VeryThinSpace]", "-", RowBox[{"75.84839458505643`", " ", "x"}], "+", RowBox[{"0.4659249962597398`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.0009439415323532654`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ RowBox[{"5", " ", "x"}], "\[Equal]", "801"}]}, { RowBox[{"84.2683188002546`", "\[VeryThinSpace]", "-", RowBox[{"0.5016368872052022`", " ", "x"}], "-", RowBox[{"0.005762324600798029`", " ", SuperscriptBox["x", "2"]}], "+", RowBox[{"0.00004127324858251942`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["403", "5"], "<", "x", "\[LessEqual]", FractionBox["602", "5"]}]}, { RowBox[{ RowBox[{"-", "62.90780464422164`"}], "+", RowBox[{"4.976382595839821`", " ", "x"}], "-", RowBox[{"0.07372782687182809`", " ", SuperscriptBox["x", "2"]}], "+", RowBox[{"0.000322354730265853`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["204", "5"], "\[LessEqual]", "x", "\[LessEqual]", FractionBox["403", "5"]}]}, { RowBox[{"34.90166049044879`", "\[VeryThinSpace]", "-", RowBox[{"2.2154898405330044`", " ", "x"}], "+", RowBox[{"0.10254355637260394`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.0011177709498357156`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{"1", "\[LessEqual]", "x", "<", FractionBox["204", "5"]}]}, { RowBox[{"110.68084486274336`", "\[VeryThinSpace]", "-", RowBox[{"1.159756307366882`", " ", "x"}], "-", RowBox[{"0.0002962164599202982`", " ", SuperscriptBox["x", "2"]}], "+", RowBox[{"0.000026140058823721722`", " ", SuperscriptBox["x", "3"]}]}], TagBox["True", "PiecewiseDefault", AutoDelete->True]} }, AllowedDimensions->{2, Automatic}, Editable->True, GridBoxAlignment->{"Columns" -> {{Left}}, "Rows" -> {{Baseline}}}, GridBoxItemSize->{"Columns" -> {{Automatic}}, "Rows" -> {{1.}}}, GridBoxSpacings->{"Columns" -> { Offset[0.27999999999999997`], { Offset[0.84]}, Offset[0.27999999999999997`]}, "Rows" -> { Offset[0.2], { Offset[0.4]}, Offset[0.2]}}, Selectable->True]} }, GridBoxAlignment->{"Columns" -> {{Left}}, "Rows" -> {{Baseline}}}, GridBoxItemSize->{"Columns" -> {{Automatic}}, "Rows" -> {{1.}}}, GridBoxSpacings->{"Columns" -> { Offset[0.27999999999999997`], { Offset[0.35]}, Offset[0.27999999999999997`]}, "Rows" -> { Offset[0.2], { Offset[0.4]}, Offset[0.2]}}], "Piecewise", DeleteWithContents->True, Editable->False, SelectWithContents->True, Selectable->False, StripWrapperBoxes->True], ",", TagBox[GridBox[{ {"\[Piecewise]", GridBox[{ {"0.`", RowBox[{ RowBox[{"x", ">", "200"}], "||", RowBox[{"x", "<", "1"}]}]}, { RowBox[{"506.1873008371448`", "\[VeryThinSpace]", "-", RowBox[{"14.13710010452489`", " ", "x"}], "+", RowBox[{"0.1428098486703393`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.0004564636295947824`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["403", "5"], "\[LessEqual]", "x", "<", FractionBox["602", "5"]}]}, { RowBox[{"983.6899016980851`", "\[VeryThinSpace]", "-", RowBox[{"15.243865326953879`", " ", "x"}], "+", RowBox[{"0.08464182566497819`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.00015526357101398446`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["801", "5"], "\[LessEqual]", "x", "\[LessEqual]", "200"}]}, { RowBox[{"59.67557906755165`", "\[VeryThinSpace]", "+", RowBox[{"1.195190328126067`", " ", "x"}], "-", RowBox[{"0.015866771900576906`", " ", SuperscriptBox["x", "2"]}], "-", RowBox[{"0.000057996728507930134`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{"1", "\[LessEqual]", "x", "<", FractionBox["204", "5"]}]}, { RowBox[{ RowBox[{"-", "759.529309544293`"}], "+", RowBox[{"17.400689190693658`", " ", "x"}], "-", RowBox[{"0.119131922884632`", " ", SuperscriptBox["x", "2"]}], "+", RowBox[{"0.0002687350734920707`", " ", SuperscriptBox["x", "3"]}]}], RowBox[{ FractionBox["602", "5"], "\[LessEqual]", "x", "<", FractionBox["801", "5"]}]}, { RowBox[{"24.222444204618753`", "\[VeryThinSpace]", "+", RowBox[{"3.8020384798123104`", " ", "x"}], "-", RowBox[{"0.07976010895171029`", " ", SuperscriptBox["x", "2"]}], "+", RowBox[{"0.0004640076591647279`", " ", SuperscriptBox["x", "3"]}]}], TagBox["True", "PiecewiseDefault", AutoDelete->True]} }, AllowedDimensions->{2, Automatic}, Editable->True, GridBoxAlignment->{"Columns" -> {{Left}}, "Rows" -> {{Baseline}}}, GridBoxItemSize->{"Columns" -> {{Automatic}}, "Rows" -> {{1.}}}, GridBoxSpacings->{"Columns" -> { Offset[0.27999999999999997`], { Offset[0.84]}, Offset[0.27999999999999997`]}, "Rows" -> { Offset[0.2], { Offset[0.4]}, Offset[0.2]}}, Selectable->True]} }, GridBoxAlignment->{"Columns" -> {{Left}}, "Rows" -> {{Baseline}}}, GridBoxItemSize->{"Columns" -> {{Automatic}}, "Rows" -> {{1.}}}, GridBoxSpacings->{"Columns" -> { Offset[0.27999999999999997`], { Offset[0.35]}, Offset[0.27999999999999997`]}, "Rows" -> { Offset[0.2], { Offset[0.4]}, Offset[0.2]}}], "Piecewise", DeleteWithContents->True, Editable->False, SelectWithContents->True, Selectable->False, StripWrapperBoxes->True]}], "}"}]], "Output", TaggingRules->{}, CellChangeTimes->{{3.780090206373105*^9, 3.780090231355466*^9}, 3.7800902679674263`*^9, {3.7800904658399973`*^9, 3.780090490626317*^9}, { 3.780090554167499*^9, 3.780090573622671*^9}, 3.780090783670001*^9, { 3.780090917545183*^9, 3.7800910218451138`*^9}, {3.780091109913517*^9, 3.780091183214184*^9}, 3.780091596926457*^9, {3.780091828229432*^9, 3.7800918357662077`*^9}, {3.780092200733347*^9, 3.780092239503593*^9}, 3.7800923370133743`*^9, {3.780092769160801*^9, 3.78009279935973*^9}, 3.78009326622432*^9, 3.7800966932117033`*^9, 3.7800970657976847`*^9, 3.7801304612866383`*^9, {3.780130554524935*^9, 3.780130582502707*^9}, 3.780130639544091*^9, 3.780138376441712*^9, 3.780330649693653*^9, 3.780334119293098*^9, 3.780336765978767*^9, 3.782464171261855*^9, 3.782651012811131*^9, 3.782652575949196*^9}, CellLabel->"Out[3]=", CellID->98789333] }, Open ]], Cell["\<\ Here is a plot of the original data and the obtained regression quantiles:\ \>", "Text", TaggingRules->{}, CellChangeTimes->{{3.780092439263586*^9, 3.780092470978085*^9}, 3.7800970763176413`*^9}, CellID->340023024], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{"ListLinePlot", "[", RowBox[{ RowBox[{"{", RowBox[{"randData", ",", RowBox[{ RowBox[{ "qFuncs", "\[LeftDoubleBracket]", "1", "\[RightDoubleBracket]"}], "/@", RowBox[{"randData", "\[LeftDoubleBracket]", RowBox[{"All", ",", "1"}], "\[RightDoubleBracket]"}]}], ",", RowBox[{ RowBox[{ "qFuncs", "\[LeftDoubleBracket]", "2", "\[RightDoubleBracket]"}], "/@", RowBox[{"randData", "\[LeftDoubleBracket]", RowBox[{"All", ",", "1"}], "\[RightDoubleBracket]"}]}]}], "}"}], ",", RowBox[{"PlotLegends", "\[Rule]", RowBox[{"{", RowBox[{"\"\\"", ",", "0.25`", ",", "0.75`"}], "}"}]}], ",", RowBox[{"PlotStyle", "\[Rule]", RowBox[{"{", RowBox[{"Thin", ",", "Thick", ",", "Thick"}], "}"}]}], ",", RowBox[{"PlotTheme", "\[Rule]", "\"\\""}]}], "]"}]], "Input", TaggingRules->{}, CellChangeTimes->{{3.78009026858465*^9, 3.780090355568449*^9}, 3.7800904537894783`*^9, {3.7800905812936993`*^9, 3.780090700349174*^9}, { 3.78009073833045*^9, 3.780090795412019*^9}, {3.780092593946312*^9, 3.780092647913769*^9}, {3.7800928172788277`*^9, 3.780092837270083*^9}, { 3.780093275686936*^9, 3.780093291502625*^9}, {3.7800966964954643`*^9, 3.780096702218973*^9}, {3.780097041947589*^9, 3.78009710819908*^9}, { 3.780130644965616*^9, 3.780130659125646*^9}}, CellLabel->"In[4]:=", CellID->326676616], Cell[BoxData[ TemplateBox[{ GraphicsBox[{{}, {{{}, {}, { Hue[0.67, 0.6, 0.6], Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]], LineBox[CompressedData[" 1:eJw1VgdUlFcWRiJKFGVUmqE4CCIiUgSRovLREYY2M/T2z8DQRCyLqCQbf9tR UGJDQYxxMLhRF4EoEgRc/z2HKFHsiIiuDAHXEgu4FiyYJcf7OIfD+bjvvvtu +b77WyqXSVXaWlpabSO/f/39/DPgXec7v2LJ0nDQP+A+NOPPFsVCwroo3zy7 5nWQN2EREqq+3LjbIoawAV4VrZetPOhD2ATTd2Xr5xhHEjZDo6Njk8PYxYTF 0JrvcLnL+qb3Zzwdro47yk33epHdGk/Xrun1LHQibINrQ1FLiz5JCNui/EGF S7HNPMJ2EGXvGXfTCYTt8d9tK9bNehNN2AED9566nPaMI+yEXJ3RM3VMAwg7 o0NvV7HoVhjhuZCXDNq8WhJC2AVDVmcjvn62gLAr2iqtal19nQnPwxqj9smN tcGE3fBkecfPd5Us/nxYFGR5jDFk8d3BO1/N9Op2JOyBunU21YnCTMKewAfc jhZkhL2gzr3KXV3H6rcAnMNL/d59LoQXIv32hLyVeuy9i1Bu31G5iV9E2BuS 6y4HHF/LCQNJf1tUPfgF9ZsHbI1Hu7+6xuw+iCxs7j/aGkp2H3zS80m9spP1 2xdaMSvW9g1Sv3lfbJ8q0tvoHEt2P2DChYYzkyzJ7gfrnQt2GN+LILs/xpie avm+nPLj/RG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6], Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]], LineBox[CompressedData[" 1:eJw1lgs41Okex0e6OrXUSHooUwkxieiCypcMEXLJ/TJj7m15WJdTWZt/zqLL 2dNBbUmXiW4kHtG2XTiTcird7Go7tdUk2pCKqSil7XSe83vneeaZ5zPf+f7f eX+3950hTQlTjODxeFe/vP/3+f9Xv+dvlk0Dt+UAfYG7XZurFzxeRjwWbwtF Hx/OXkpsglZh0EpdqQexKVxPmpnneroTm6N3jOCBibEbsSWanLsmtI1dTCxA jtXzORMdFhHPxNvmo8f5GQuJrfF0aqnhrI4FxDYQmIjqC9IZ2yF1/0zXbTaM 7XHwp9rhtCFXYiE2hKQWbHvO2BFXxA+Dpr5n7ITI++nXVALmd0ZfbX16YxLj +RDrLP+tOMfYBanh9u5H7dj/c0XvqDj/q5WMF2Dfc2GyqSfbz0KEDE6zautk vAi3p1XdC9zN9r8Yf0RE8FuiWHzckFi8e0XxLBY/dxhc79f3v2fsgQN63RaH uyzeSzD88XH+9rNLiJeiS/eNIuYQy88yCHdMOvBoO8ufJ4oMUClZ70kMZEy+ sHmyM+WbAz7k7Cv0PsLy74VL7tzFuClepHvBBTbBefnEPG/UbAvK6NQz3RsH TE+n7o32Jn055PcsuFtnibnlULXicbnpctJ9MP5dR8syNTHng7Q0ZfulOqaL 8HH/u+Zjg0wXYXB//6mJzj6k+2L4+8ExXjJizheHFdWzM39guh9ywxrWvaxh uh/mJV5d2tPC9BVAacbQMR3TV8DfUsVb08t0f/zxxqdurZ7p/qhwrUvr62d6 AOz1kQddnjM9AAZLfitZ/4jpK3HRtq3pA1uPWwnDKwNZw6eYHohEYcfMC7uY Hgjl10stNqYzPQh1xVWX0wKZHoQH5+7kdAuYHoz017Enp+pZfIJhFvT0pKiB xW8VIh9N7jiRx/RVaDm9s3J7ANNDML5nlNp6PDFCUL31q29Pt7B8hWBFZbjP pnxibQj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VImRN qyjTl/qlXQoz/yKzjJusf2QQhb63i4+lfhPIUFYbe3nRS9aPMrwqmeg0MZ/6 V/KF3TLrXltTv3MyqC8+2vXsGrFGBgtJ+fR37P6kleG2aPouRxuaJ+0y+JUd xe5H7D4ih8+RnWqPUppHAjkc7DpMxojZPJPj1c3y4tF2NO8kcojPN/+l4y0x J8ebUhsLr8s0HzVyWFkckV3fSfNUK0fiU6sCOwXN23Y5BOWZtjxXdh9R4MmI vGdDn4kFCvBrhMqGKzTfocDuitnWQz40/yUKRNwUT9GUsfNBge/M6xNsh4k1 Clxvn3i1I4SdNwp8+FZta6Mhbleg2fNYoKiHnT9KdG1uGLvTwZvWV8Jyz16h UkkMJazuzd1qXEIsUaJyt7Kvs4mYU2KD0NVpUSexRgm/F3mWCUPEWiVuCVfm VYyk87VdiRvL0z1SGfNUGMp/aTzqPVtfhUmBFW3ndWx9Fdq6d0V1n2Hrq/Dm VNk6XS5bX4X5vH916pex9VXwt/n9h7/2sv1/+X1Wp4e2gO1fhefhLY0z+Wz/ arwYvalL/3eKn0ANeduDCYY9LP5q9JdPehhQRPmRqKG3z3kgNaV8cmro+Lzq 18ks/2o4GmUMHNpP9aNVI+rs2XDzMlZ/aty8UfP1p43sPr0G4/pdH76f5YL/ AiS6cS0= "]]}, { Hue[0.1421359549995791, 0.6, 0.6], Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]], LineBox[CompressedData[" 1:eJw9lgtYzOkex0fFiZS2I0tFbfaUTdKV0OW76H6d6TLdm/tMUalN6LQZJZeU 4hxKLFmUUCsGOUenya4WraPbRpu2DpUiot0NHcs6z3l/zfPMM89nvvN9vu/8 3t/vff+fiFJ4Ug0Oh3Pzw/t/n/9/vXB/bJVZsC4pEOwLOHhWblnNCWKsjfCq JPXYXmJ9GB/syaqbGcx4NuLa3XrvBxHPhXhza3tHMbEJzFJnVlbcJTbDzirZ Ke+Z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fuQxeRS2jmk60/zJoPO2saHKl/ZfBsOXB9DxP ypfjl4CCH5fS86KZHLPSi5qu8Clfjh5u8SFdAeXL0TLurGOuoHw5otMc7g+k UL4cL9s/q/fZRPlyTFvclOGWTfly6O680KiafP5UIPNVadRX+ZSvQP2ehe+G iihfgYCQt4pdf6d8BY7E3uGvn3xeU8D4H9iZd5jyFcBmjuq7ryhfga2Vl8uM 6LzqU8CHr/t60+T5lYCPSmp23fkwj38ArWSERg== "]]}}, {{ Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]]}}, {{ Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]]}, {}, {}, {}, {}, {}, {}, {}}, {{ Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]]}, { Directive[ PointSize[ NCache[ Rational[1, 120], 0.008333333333333333]], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]]}, {}, {}, {}, {}, {}, {}, {}}}, {{}, {}}}, { DisplayFunction -> Identity, DisplayFunction -> Identity, AspectRatio -> NCache[GoldenRatio^(-1), 0.6180339887498948], Axes -> {False, False}, AxesLabel -> {None, None}, AxesOrigin -> {0., 0}, DisplayFunction :> Identity, Frame -> {{True, True}, {True, True}}, FrameLabel -> {{None, None}, {None, None}}, FrameStyle -> Automatic, FrameTicks -> {{Automatic, Automatic}, {Automatic, Automatic}}, GridLines -> {Automatic, Automatic}, GridLinesStyle -> Directive[ GrayLevel[0.4, 0.5], AbsoluteThickness[1], AbsoluteDashing[{1, 2}]], Method -> { "OptimizePlotMarkers" -> True, "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ (Identity[#]& )[ Part[#, 1]], (Identity[#]& )[ Part[#, 2]]}& ), "CopiedValueFunction" -> ({ (Identity[#]& )[ Part[#, 1]], (Identity[#]& )[ Part[#, 2]]}& )}}, PlotRange -> {{0., 200.}, {0, 97.0634149995362}}, PlotRangeClipping -> True, PlotRangePadding -> {{ Scaled[0.02], Scaled[0.02]}, { Scaled[0.02], Scaled[0.05]}}, Ticks -> {Automatic, Automatic}}], FormBox[ FormBox[ TemplateBox[{"\"data\"", "0.25`", "0.75`"}, "LineLegend", DisplayFunction -> (FormBox[ StyleBox[ StyleBox[ PaneBox[ TagBox[ GridBox[{{ TagBox[ GridBox[{{ GraphicsBox[{{ Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]], { LineBox[{{0, 10}, {20, 10}}]}}, { Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6], Thickness[Tiny]], {}}}, AspectRatio -> Full, ImageSize -> {20, 10}, PlotRangePadding -> None, ImagePadding -> Automatic, BaselinePosition -> (Scaled[0.1] -> Baseline)], #}, { GraphicsBox[{{ Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]], { LineBox[{{0, 10}, {20, 10}}]}}, { Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6], Thickness[Large]], {}}}, AspectRatio -> Full, ImageSize -> {20, 10}, PlotRangePadding -> None, ImagePadding -> Automatic, BaselinePosition -> (Scaled[0.1] -> Baseline)], #2}, { GraphicsBox[{{ Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]], { LineBox[{{0, 10}, {20, 10}}]}}, { Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.560181, 0.691569, 0.194885], AbsoluteThickness[1.6], Thickness[Large]], {}}}, AspectRatio -> Full, ImageSize -> {20, 10}, PlotRangePadding -> None, ImagePadding -> Automatic, BaselinePosition -> (Scaled[0.1] -> Baseline)], #3}}, GridBoxAlignment -> { "Columns" -> {Center, Left}, "Rows" -> {{Baseline}}}, AutoDelete -> False, GridBoxDividers -> { "Columns" -> {{False}}, "Rows" -> {{False}}}, GridBoxItemSize -> {"Columns" -> {{All}}, "Rows" -> {{All}}}, GridBoxSpacings -> { "Columns" -> {{0.5}}, "Rows" -> {{0.8}}}], "Grid"]}}, GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}}, AutoDelete -> False, GridBoxItemSize -> { "Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}}, GridBoxSpacings -> {"Columns" -> {{1}}, "Rows" -> {{0}}}], "Grid"], Alignment -> Left, AppearanceElements -> None, ImageMargins -> {{5, 5}, {5, 5}}, ImageSizeAction -> "ResizeToFit"], LineIndent -> 0, StripOnInput -> False], { FontFamily -> "Arial"}, Background -> Automatic, StripOnInput -> False], TraditionalForm]& ), InterpretationFunction :> (RowBox[{"LineLegend", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"Directive", "[", RowBox[{ RowBox[{"PointSize", "[", FractionBox["1", "120"], "]"}], ",", InterpretationBox[ ButtonBox[ TooltipBox[ GraphicsBox[{{ GrayLevel[0], RectangleBox[{0, 0}]}, { GrayLevel[0], RectangleBox[{1, -1}]}, { RGBColor[0.368417, 0.506779, 0.709798], RectangleBox[{0, -1}, {2, 1}]}}, DefaultBaseStyle -> "ColorSwatchGraphics", AspectRatio -> 1, Frame -> True, FrameStyle -> RGBColor[ 0.24561133333333335`, 0.3378526666666667, 0.4731986666666667], FrameTicks -> None, PlotRangePadding -> None, ImageSize -> Dynamic[{ Automatic, 1.35 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[ Magnification])}]], StyleBox[ RowBox[{"RGBColor", "[", RowBox[{"0.368417`", ",", "0.506779`", ",", "0.709798`"}], "]"}], NumberMarks -> False]], Appearance -> None, BaseStyle -> {}, BaselinePosition -> Baseline, DefaultBaseStyle -> {}, ButtonFunction :> With[{Typeset`box$ = EvaluationBox[]}, If[ Not[ AbsoluteCurrentValue["Deployed"]], SelectionMove[Typeset`box$, All, Expression]; FrontEnd`Private`$ColorSelectorInitialAlpha = 1; FrontEnd`Private`$ColorSelectorInitialColor = RGBColor[0.368417, 0.506779, 0.709798]; FrontEnd`Private`$ColorSelectorUseMakeBoxes = True; MathLink`CallFrontEnd[ FrontEnd`AttachCell[Typeset`box$, FrontEndResource["RGBColorValueSelector"], { 0, {Left, Bottom}}, {Left, Top}, "ClosingActions" -> { "SelectionDeparture", "ParentChanged", "EvaluatorQuit"}]]]], BaseStyle -> Inherited, Evaluator -> Automatic, Method -> "Preemptive"], RGBColor[0.368417, 0.506779, 0.709798], Editable -> False, Selectable -> False], ",", RowBox[{"AbsoluteThickness", "[", "1.6`", "]"}], ",", RowBox[{"Thickness", "[", "Tiny", "]"}]}], "]"}], ",", RowBox[{"Directive", "[", RowBox[{ RowBox[{"PointSize", "[", FractionBox["1", "120"], "]"}], ",", InterpretationBox[ ButtonBox[ TooltipBox[ GraphicsBox[{{ GrayLevel[0], RectangleBox[{0, 0}]}, { GrayLevel[0], RectangleBox[{1, -1}]}, { RGBColor[0.880722, 0.611041, 0.142051], RectangleBox[{0, -1}, {2, 1}]}}, DefaultBaseStyle -> "ColorSwatchGraphics", AspectRatio -> 1, Frame -> True, FrameStyle -> RGBColor[ 0.587148, 0.40736066666666665`, 0.09470066666666668], FrameTicks -> None, PlotRangePadding -> None, ImageSize -> Dynamic[{ Automatic, 1.35 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[ Magnification])}]], StyleBox[ RowBox[{"RGBColor", "[", RowBox[{"0.880722`", ",", "0.611041`", ",", "0.142051`"}], "]"}], NumberMarks -> False]], Appearance -> None, BaseStyle -> {}, BaselinePosition -> Baseline, DefaultBaseStyle -> {}, ButtonFunction :> With[{Typeset`box$ = EvaluationBox[]}, If[ Not[ AbsoluteCurrentValue["Deployed"]], SelectionMove[Typeset`box$, All, Expression]; FrontEnd`Private`$ColorSelectorInitialAlpha = 1; FrontEnd`Private`$ColorSelectorInitialColor = RGBColor[0.880722, 0.611041, 0.142051]; FrontEnd`Private`$ColorSelectorUseMakeBoxes = True; MathLink`CallFrontEnd[ FrontEnd`AttachCell[Typeset`box$, FrontEndResource["RGBColorValueSelector"], { 0, {Left, Bottom}}, {Left, Top}, "ClosingActions" -> { "SelectionDeparture", "ParentChanged", "EvaluatorQuit"}]]]], BaseStyle -> Inherited, Evaluator -> Automatic, Method -> "Preemptive"], RGBColor[0.880722, 0.611041, 0.142051], Editable -> False, Selectable -> False], ",", RowBox[{"AbsoluteThickness", "[", "1.6`", "]"}], ",", RowBox[{"Thickness", "[", "Large", "]"}]}], "]"}], ",", RowBox[{"Directive", "[", RowBox[{ RowBox[{"PointSize", "[", FractionBox["1", "120"], "]"}], ",", InterpretationBox[ ButtonBox[ TooltipBox[ GraphicsBox[{{ GrayLevel[0], RectangleBox[{0, 0}]}, { GrayLevel[0], RectangleBox[{1, -1}]}, { RGBColor[0.560181, 0.691569, 0.194885], RectangleBox[{0, -1}, {2, 1}]}}, DefaultBaseStyle -> "ColorSwatchGraphics", AspectRatio -> 1, Frame -> True, FrameStyle -> RGBColor[ 0.37345400000000006`, 0.461046, 0.12992333333333334`], FrameTicks -> None, PlotRangePadding -> None, ImageSize -> Dynamic[{ Automatic, 1.35 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[ Magnification])}]], StyleBox[ RowBox[{"RGBColor", "[", RowBox[{"0.560181`", ",", "0.691569`", ",", "0.194885`"}], "]"}], NumberMarks -> False]], Appearance -> None, BaseStyle -> {}, BaselinePosition -> Baseline, DefaultBaseStyle -> {}, ButtonFunction :> With[{Typeset`box$ = EvaluationBox[]}, If[ Not[ AbsoluteCurrentValue["Deployed"]], SelectionMove[Typeset`box$, All, Expression]; FrontEnd`Private`$ColorSelectorInitialAlpha = 1; FrontEnd`Private`$ColorSelectorInitialColor = RGBColor[0.560181, 0.691569, 0.194885]; FrontEnd`Private`$ColorSelectorUseMakeBoxes = True; MathLink`CallFrontEnd[ FrontEnd`AttachCell[Typeset`box$, FrontEndResource["RGBColorValueSelector"], { 0, {Left, Bottom}}, {Left, Top}, "ClosingActions" -> { "SelectionDeparture", "ParentChanged", "EvaluatorQuit"}]]]], BaseStyle -> Inherited, Evaluator -> Automatic, Method -> "Preemptive"], RGBColor[0.560181, 0.691569, 0.194885], Editable -> False, Selectable -> False], ",", RowBox[{"AbsoluteThickness", "[", "1.6`", "]"}], ",", RowBox[{"Thickness", "[", "Large", "]"}]}], "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{#, ",", #2, ",", #3}], "}"}], ",", RowBox[{"LegendMarkers", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"False", ",", "Automatic"}], "}"}], ",", RowBox[{"{", RowBox[{"False", ",", "Automatic"}], "}"}], ",", RowBox[{"{", RowBox[{"False", ",", "Automatic"}], "}"}]}], "}"}]}], ",", RowBox[{"Joined", "\[Rule]", RowBox[{"{", RowBox[{"True", ",", "True", ",", "True"}], "}"}]}], ",", RowBox[{"LabelStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"LegendLayout", "\[Rule]", "\"Column\""}]}], "]"}]& ), Editable -> True], TraditionalForm], TraditionalForm]}, "Legended", DisplayFunction->(GridBox[{{ TagBox[ ItemBox[ PaneBox[ TagBox[#, "SkipImageSizeLevel"], Alignment -> {Center, Baseline}, BaselinePosition -> Baseline], DefaultBaseStyle -> "Labeled"], "SkipImageSizeLevel"], ItemBox[#2, DefaultBaseStyle -> "LabeledLabel"]}}, GridBoxAlignment -> {"Columns" -> {{Center}}, "Rows" -> {{Center}}}, AutoDelete -> False, GridBoxItemSize -> Automatic, BaselinePosition -> {1, 1}]& ), Editable->True, InterpretationFunction->(RowBox[{"Legended", "[", RowBox[{#, ",", RowBox[{"Placed", "[", RowBox[{#2, ",", "After"}], "]"}]}], "]"}]& )]], "Output", TaggingRules->{}, CellChangeTimes->{{3.7800903309245*^9, 3.780090356223015*^9}, { 3.780090454996011*^9, 3.780090496041542*^9}, {3.78009055584441*^9, 3.7800905750088053`*^9}, {3.780090624216156*^9, 3.780090701577004*^9}, { 3.780090769925888*^9, 3.780090796162401*^9}, {3.780090920285935*^9, 3.780091022053643*^9}, {3.78009111238482*^9, 3.7800911842713413`*^9}, 3.7800915981191597`*^9, {3.780091830462552*^9, 3.78009183673175*^9}, { 3.780092200919949*^9, 3.78009223968087*^9}, 3.780092339359828*^9, { 3.780092615790535*^9, 3.780092648440567*^9}, {3.780092770892043*^9, 3.780092837806592*^9}, {3.7800932857158422`*^9, 3.7800932920017433`*^9}, 3.780096702877512*^9, {3.780097060987172*^9, 3.780097109953703*^9}, 3.780130461485395*^9, {3.780130554848102*^9, 3.780130582707415*^9}, { 3.780130639799122*^9, 3.780130661745335*^9}, 3.780138376623657*^9, 3.7803306503260202`*^9, 3.780334119549725*^9, 3.780336766269215*^9, 3.782464171517983*^9, 3.782651013359178*^9, 3.78265257632609*^9}, CellLabel->"Out[4]=", CellID->418215499] }, Open ]], Cell["\<\ Find the fraction of the data points that are under the second regression \ quantile:\ \>", "Text", TaggingRules->{}, CellChangeTimes->{{3.7800918537718077`*^9, 3.780091894384305*^9}, { 3.780092211197259*^9, 3.780092212522031*^9}, {3.7800926692541037`*^9, 3.780092689190442*^9}, {3.780093308006234*^9, 3.7800933100980186`*^9}}, CellID->86396137], Cell[CellGroupData[{ Cell[BoxData[ RowBox[{ RowBox[{ RowBox[{"Length", "[", RowBox[{"Select", "[", RowBox[{"randData", ",", RowBox[{ RowBox[{ RowBox[{"#", "\[LeftDoubleBracket]", "2", "\[RightDoubleBracket]"}], "<", RowBox[{ RowBox[{ "qFuncs", "\[LeftDoubleBracket]", "2", "\[RightDoubleBracket]"}], "[", RowBox[{"#", "\[LeftDoubleBracket]", "1", "\[RightDoubleBracket]"}], "]"}]}], "&"}]}], "]"}], "]"}], "/", RowBox[{"Length", "[", "randData", "]"}]}], "//", "N"}]], "Input", TaggingRules->{}, CellChangeTimes->{{3.780092280234021*^9, 3.780092301457436*^9}, { 3.780092346076633*^9, 3.7800924293530188`*^9}, {3.780093297748917*^9, 3.780093297836669*^9}, {3.780096710208897*^9, 3.780096715743843*^9}, { 3.780130597762136*^9, 3.780130604513029*^9}}, CellLabel->"In[5]:=", CellID->207153374], Cell[BoxData["0.75`"], "Output", TaggingRules->{}, CellChangeTimes->{{3.780092376979115*^9, 3.780092429884076*^9}, { 3.7800927736714897`*^9, 3.780092803159334*^9}, 3.780092841661002*^9, { 3.780093293970414*^9, 3.780093298517247*^9}, {3.7800967105400352`*^9, 3.78009671601081*^9}, 3.780097066069601*^9, 3.78013046155548*^9, { 3.78013055490691*^9, 3.780130605994845*^9}, 3.780130639851561*^9, 3.780138376677806*^9, 3.78033065148483*^9, 3.780334119609034*^9, 3.780336766334859*^9, 3.7824641716018476`*^9, 3.782651013524321*^9, 3.7826525764068813`*^9}, CellLabel->"Out[5]=", CellID->700810692] }, Open ]], Cell[TextData[{ "The obtained fraction is close to the second probability, ", Cell[BoxData[ FormBox["0.75", TraditionalForm]]], ", given to ", Cell[BoxData["QuantileRegression"], "InlineFormula", FontFamily->"Source Sans Pro"], "." }], "Text", TaggingRules->{}, CellChangeTimes->{{3.780092662110724*^9, 3.780092749020361*^9}, { 3.780093334085732*^9, 3.780093347955913*^9}, 3.782465182143615*^9}, CellID->231888806] }, Open ]], Cell[CellGroupData[{ Cell["Scope", "Subsection", TaggingRules->{}, CellID->204653245], Cell["\<\ Here is a quantile regression computation over a numerical vector:\ \>", "Text", TaggingRules->{}, CellChangeTimes->{{3.780335943413865*^9, 3.780335968028062*^9}, { 3.782465188762457*^9, 3.78246518913369*^9}, {3.7857867891092577`*^9, 3.785786789400081*^9}}, CellID->303738464], Cell[CellGroupData[{ Cell[BoxData[{ RowBox[{ RowBox[{"vecData", "=", RowBox[{ RowBox[{"Sin", "[", RowBox[{ RowBox[{"Range", "[", "200", "]"}], "/", "6"}], "]"}], "+", RowBox[{"RandomReal", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"-", "0.5"}], ",", "0.5"}], "}"}], ",", "200"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{ RowBox[{"qFunc", "=", RowBox[{"First", "@", RowBox[{"QuantileRegression", "[", RowBox[{"vecData", ",", "12", ",", "0.5"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"ListLinePlot", "[", RowBox[{ RowBox[{"{", RowBox[{"vecData", ",", RowBox[{ RowBox[{ RowBox[{"qFunc", "[", "#", "]"}], "&"}], "/@", RowBox[{"Range", "[", RowBox[{"Length", "[", "vecData", "]"}], "]"}]}]}], "}"}], ",", RowBox[{"PlotRange", "\[Rule]", "All"}], ",", RowBox[{"PlotTheme", "\[Rule]", "\"\\""}], ",", RowBox[{"PlotLegends", "\[Rule]", RowBox[{"{", RowBox[{"\"\\"", ",", "\"\\""}], "}"}]}]}], "]"}]}], "Input", TaggingRules->{}, CellChangeTimes->{{3.780335979965549*^9, 3.780336212732834*^9}, { 3.780336251322982*^9, 3.7803363570867662`*^9}}, CellLabel->"In[1]:=", CellID->603420785], Cell[BoxData[ TemplateBox[{ GraphicsBox[{{}, {{{}, {}, { Hue[0.67, 0.6, 0.6], Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]], LineBox[CompressedData[" 1:eJw1VgdUU9kWjQXEApaxYI+IDVDBQlARtoKNJoRQQg0hjREp0kbFMcK3fv2i 4yBYAw6o8MVRxG/5Ok9Q8IMUURBFMEhTOggqMurMXzkva7GyNvuee+7bZ2ff N0scypcO5nA4j//++/+35tNlHfJw9roRXiV/0D9Q9tJ+m4lOlrUG6uB6/RRV Tdx7wmNwMyomt57bRXg8zmzSK6oa94GwPrRzbNYvX9FLeBpet7h66E5QE+bi SazeUq3iWsIGiDTY8tm1k93PEAYWdt5n+z8SnouSgbn5Ni7dhOfjo1AYkVLD YiNELm+McYhisQnU0rBt43PaCS+Ckd1L61sxTYRN0RpfsHCsooKwGX6aJLjR aFtEeAlG8iL0rw4rJLwUX1IWRWpNrCa8DD68a0VWu0sIL0eIlu+njsQC0s8c 3O3WJYXvTxDmQdU/zV/nX+WELeDn6OY/3/gD4RXg21YyY3peEF6JlHWJ1tE1 HYRXoVXIGJUf7SVsiaCDzsHHxPWEV8MgxHfE2DtdhK1g9mgP93Mky1ujdeXW xfaPWAy8LXygm/qyUYOVwPcdgbwa7U7i1yC5+PaQh4m0XrkGVW0zZj5fcZX4 tegShhvVjbimeX7lWvDejL12V/2KeBu8HOBmG5yjeSttMPH1zAOzFOWkly2U X81vz6qWEW8Lx/knTn+Z3Uz8Oujr9i95xrwjfh3Mrm9ddL6Gnd96dC14dGim E81DuR7i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ointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]], LineBox[CompressedData[" 1:eJw1lgs4Vfkaxjc13agwTpnRuLRlUEd3ZSvepEiue6O9RfbFvpQMY1QyTbZK R1TndDM9iD1JZcqlpgw1mqVUJqrt3sVlj8pIaoR0TiOd5vEtz+Px/LzrXf+1 vv/3f79lLY3hy/U5HE71x9+//47+9LntC+GumhR671f6B/p2t0iMA7VuozgB rpkHA/TrnxIbIap0fMDRvFfEptDt7xDGv+wnNsNV2ZRfGkPfEM/ARkkVnykb IrbCrn8ttjC0fUs8E+dajlkeqGR1G6gFnwnNfmT9ttAMD1TvGhkgtsPZRtE3 P7S9JnZA7JX3JYdr2eeZA91cx4Gcr54TO+KRYWGxcccT4nlYVFBVZ/9zK/F8 XDfd7J6/sp54Aa6b3e+PuVJJvBDac501cU6pxItwsOH3qOboMqrXYtxxDnv7 KuM2sRNmvtT2pkRoiZfAoi/mfmN3A/FShMzLHHs8oZnYGX5lG6LHWD0g5kF9 uLbHu49lF2z+rT/85DuWl+G4UndmeQDLy7Fr26mCAP0WYldoxvh5TJ3ZROyG HdN6hYVMPTHA3WJ+qKL9/iirgZuDu7uLdv5G+go8ZOYmZuy+TvoK1PqbGD6y LCXdHX1pCQadizJJd8dWL5mtUdNJqs9KlLYntC5JLh9l9UpM+qkgSVBWRboH Hu+bUsffXku6Bzxia9+hr470VWgNdFFHyptIXwUz3Sb91LQHpK+Gj3F/mqXf Y9JXo/mxkpub00a6J0ycZE2JmzpI98Ts9OXBnwboSPdCkjM3xOB7YrUXFlo7 xkUks/oabKuwL1ozjtXXYM/E4WYHXjvp3hBuNslLSWPX94Ym5cS0PTPY51sL Me+0UYlJI+lrYd2xSWdreZ90H4SZnrWLjbpJug8mVMyOzc0pJd0XCdvEtUff q0n3xQ7fqNJr5hep/n4wldYk36pi98cP58TPVdX3a0j3x9Je14LuwTrS/VGW 5MJ0Kdh+CEBjiiQzy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fnSJEQ /7LwbhC7vhSf/3zq32n1lJeQgjP+2kP7CfT8YinyUrYpk1/T+6mlCDuMtGo/ mvcaKb59/XiTwJHymJHiKJNdcnxOOa0vRWaqe4SO9yOtLwPHQlCnbl9H68vg otj+ReXxAtpPGU6N2Wb+6awroyyWwent+6zqSzdof2UIay9appxzZ5Q1MgwV zj4RM4e+1xgZ3L2ZuU2G1D86GVTNIhfrM9RvnEicf7os3+gF5aVVJOLGF/HF 1Q9p/Ujo1722u+tI800ciaIGn8mmUyiP1JHQ/jDm2etgYs3H+90NPcYdouuZ SGQ/zxijaH9E60di1+d2FUkj7HyUY3XufD09AZ0HKzk8UjwH69+y50mO8Q9S S2ab36P15fDp+qS9YSM7L+UY6d76vMK5jNaXo33q0PWo80dofTlOVkf5qmdT 3unkqFb94mD/hPqXo0CW1Mh7sgnNIysFeFrt0Ky17P4rcPTrNi/+dLb/FCjd IhC98GHzSQGj5cKugBrKP40C4+yMizq/pnxjFBjOyPuKY0X5p1NA2rOoa+Jl Nv+U8CqKk6eYUP5ZKdHTo7kjXsbOUyWuZSQeXMynfhUrkVfgkFPTzeazEvL/ TA4+s5fyTvPx+lybtxP/ov5ilDhk21aYWHae6q+E1c7UniUf2PmpQtn3ucmd 5VRvKxWKDMpa1fm0X1DhzV8u8ZMCaR6JVShojVyZ40nzS61CdHNNrbctfV9r Pt5vukKvo7WX6q9CktL0+dF/9tH6KoQfG2v2XTX7vb4RxXNGUqYuGXD7P7wf AXc= "]]}}, {{ Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]]}, { Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]]}}, {{ Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]]}, { Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]]}, {}, {}, {}}, {{ Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]]}, { Directive[ PointSize[ NCache[ Rational[1, 90], 0.011111111111111112`]], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]]}, {}, {}, {}}}, {{}, {}}}, { DisplayFunction -> Identity, DisplayFunction -> Identity, AspectRatio -> NCache[GoldenRatio^(-1), 0.6180339887498948], Axes -> {False, False}, AxesLabel -> {None, None}, AxesOrigin -> {0, 0}, DisplayFunction :> Identity, Frame -> {{True, True}, {True, True}}, FrameLabel -> {{None, None}, {None, None}}, FrameStyle -> Automatic, FrameTicks -> {{Automatic, Automatic}, {Automatic, Automatic}}, GridLines -> {Automatic, Automatic}, GridLinesStyle -> Directive[ GrayLevel[0.4, 0.5], AbsoluteThickness[1], AbsoluteDashing[{1, 2}]], Method -> { "OptimizePlotMarkers" -> True, "CoordinatesToolOptions" -> {"DisplayFunction" -> ({ (Identity[#]& )[ Part[#, 1]], (Identity[#]& )[ Part[#, 2]]}& ), "CopiedValueFunction" -> ({ (Identity[#]& )[ Part[#, 1]], (Identity[#]& )[ Part[#, 2]]}& )}}, PlotRange -> {{0, 200.}, {-1.355917868879993, 1.4743475748324684`}}, PlotRangeClipping -> True, PlotRangePadding -> {{ Scaled[0.02], Scaled[0.02]}, { Scaled[0.05], Scaled[0.05]}}, Ticks -> {Automatic, Automatic}}], FormBox[ FormBox[ TemplateBox[{"\"vector\"", "\"fit\""}, "LineLegend", DisplayFunction -> (FormBox[ StyleBox[ StyleBox[ PaneBox[ TagBox[ GridBox[{{ TagBox[ GridBox[{{ GraphicsBox[{{ Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]], { LineBox[{{0, 10}, {20, 10}}]}}, { Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.368417, 0.506779, 0.709798], AbsoluteThickness[1.6]], {}}}, AspectRatio -> Full, ImageSize -> {20, 10}, PlotRangePadding -> None, ImagePadding -> Automatic, BaselinePosition -> (Scaled[0.1] -> Baseline)], #}, { GraphicsBox[{{ Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]], { LineBox[{{0, 10}, {20, 10}}]}}, { Directive[ EdgeForm[ Directive[ Opacity[0.3], GrayLevel[0]]], PointSize[0.5], RGBColor[0.880722, 0.611041, 0.142051], AbsoluteThickness[1.6]], {}}}, AspectRatio -> Full, ImageSize -> {20, 10}, PlotRangePadding -> None, ImagePadding -> Automatic, BaselinePosition -> (Scaled[0.1] -> Baseline)], #2}}, GridBoxAlignment -> { "Columns" -> {Center, Left}, "Rows" -> {{Baseline}}}, AutoDelete -> False, GridBoxDividers -> { "Columns" -> {{False}}, "Rows" -> {{False}}}, GridBoxItemSize -> {"Columns" -> {{All}}, "Rows" -> {{All}}}, GridBoxSpacings -> { "Columns" -> {{0.5}}, "Rows" -> {{0.8}}}], "Grid"]}}, GridBoxAlignment -> {"Columns" -> {{Left}}, "Rows" -> {{Top}}}, AutoDelete -> False, GridBoxItemSize -> { "Columns" -> {{Automatic}}, "Rows" -> {{Automatic}}}, GridBoxSpacings -> {"Columns" -> {{1}}, "Rows" -> {{0}}}], "Grid"], Alignment -> Left, AppearanceElements -> None, ImageMargins -> {{5, 5}, {5, 5}}, ImageSizeAction -> "ResizeToFit"], LineIndent -> 0, StripOnInput -> False], { FontFamily -> "Arial"}, Background -> Automatic, StripOnInput -> False], TraditionalForm]& ), InterpretationFunction :> (RowBox[{"LineLegend", "[", RowBox[{ RowBox[{"{", RowBox[{ RowBox[{"Directive", "[", RowBox[{ RowBox[{"PointSize", "[", FractionBox["1", "90"], "]"}], ",", InterpretationBox[ ButtonBox[ TooltipBox[ GraphicsBox[{{ GrayLevel[0], RectangleBox[{0, 0}]}, { GrayLevel[0], RectangleBox[{1, -1}]}, { RGBColor[0.368417, 0.506779, 0.709798], RectangleBox[{0, -1}, {2, 1}]}}, DefaultBaseStyle -> "ColorSwatchGraphics", AspectRatio -> 1, Frame -> True, FrameStyle -> RGBColor[ 0.24561133333333335`, 0.3378526666666667, 0.4731986666666667], FrameTicks -> None, PlotRangePadding -> None, ImageSize -> Dynamic[{ Automatic, 1.35 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[ Magnification])}]], StyleBox[ RowBox[{"RGBColor", "[", RowBox[{"0.368417`", ",", "0.506779`", ",", "0.709798`"}], "]"}], NumberMarks -> False]], Appearance -> None, BaseStyle -> {}, BaselinePosition -> Baseline, DefaultBaseStyle -> {}, ButtonFunction :> With[{Typeset`box$ = EvaluationBox[]}, If[ Not[ AbsoluteCurrentValue["Deployed"]], SelectionMove[Typeset`box$, All, Expression]; FrontEnd`Private`$ColorSelectorInitialAlpha = 1; FrontEnd`Private`$ColorSelectorInitialColor = RGBColor[0.368417, 0.506779, 0.709798]; FrontEnd`Private`$ColorSelectorUseMakeBoxes = True; MathLink`CallFrontEnd[ FrontEnd`AttachCell[Typeset`box$, FrontEndResource["RGBColorValueSelector"], { 0, {Left, Bottom}}, {Left, Top}, "ClosingActions" -> { "SelectionDeparture", "ParentChanged", "EvaluatorQuit"}]]]], BaseStyle -> Inherited, Evaluator -> Automatic, Method -> "Preemptive"], RGBColor[0.368417, 0.506779, 0.709798], Editable -> False, Selectable -> False], ",", RowBox[{"AbsoluteThickness", "[", "1.6`", "]"}]}], "]"}], ",", RowBox[{"Directive", "[", RowBox[{ RowBox[{"PointSize", "[", FractionBox["1", "90"], "]"}], ",", InterpretationBox[ ButtonBox[ TooltipBox[ GraphicsBox[{{ GrayLevel[0], RectangleBox[{0, 0}]}, { GrayLevel[0], RectangleBox[{1, -1}]}, { RGBColor[0.880722, 0.611041, 0.142051], RectangleBox[{0, -1}, {2, 1}]}}, DefaultBaseStyle -> "ColorSwatchGraphics", AspectRatio -> 1, Frame -> True, FrameStyle -> RGBColor[ 0.587148, 0.40736066666666665`, 0.09470066666666668], FrameTicks -> None, PlotRangePadding -> None, ImageSize -> Dynamic[{ Automatic, 1.35 (CurrentValue["FontCapHeight"]/AbsoluteCurrentValue[ Magnification])}]], StyleBox[ RowBox[{"RGBColor", "[", RowBox[{"0.880722`", ",", "0.611041`", ",", "0.142051`"}], "]"}], NumberMarks -> False]], Appearance -> None, BaseStyle -> {}, BaselinePosition -> Baseline, DefaultBaseStyle -> {}, ButtonFunction :> With[{Typeset`box$ = EvaluationBox[]}, If[ Not[ AbsoluteCurrentValue["Deployed"]], SelectionMove[Typeset`box$, All, Expression]; FrontEnd`Private`$ColorSelectorInitialAlpha = 1; FrontEnd`Private`$ColorSelectorInitialColor = RGBColor[0.880722, 0.611041, 0.142051]; FrontEnd`Private`$ColorSelectorUseMakeBoxes = True; MathLink`CallFrontEnd[ FrontEnd`AttachCell[Typeset`box$, FrontEndResource["RGBColorValueSelector"], { 0, {Left, Bottom}}, {Left, Top}, "ClosingActions" -> { "SelectionDeparture", "ParentChanged", "EvaluatorQuit"}]]]], BaseStyle -> Inherited, Evaluator -> Automatic, Method -> "Preemptive"], RGBColor[0.880722, 0.611041, 0.142051], Editable -> False, Selectable -> False], ",", RowBox[{"AbsoluteThickness", "[", "1.6`", "]"}]}], "]"}]}], "}"}], ",", RowBox[{"{", RowBox[{#, ",", #2}], "}"}], ",", RowBox[{"LegendMarkers", "\[Rule]", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"False", ",", "Automatic"}], "}"}], ",", RowBox[{"{", RowBox[{"False", ",", "Automatic"}], "}"}]}], "}"}]}], ",", RowBox[{"Joined", "\[Rule]", RowBox[{"{", RowBox[{"True", ",", "True"}], "}"}]}], ",", RowBox[{"LabelStyle", "\[Rule]", RowBox[{"{", "}"}]}], ",", RowBox[{"LegendLayout", "\[Rule]", "\"Column\""}]}], "]"}]& ), Editable -> True], TraditionalForm], TraditionalForm]}, "Legended", DisplayFunction->(GridBox[{{ TagBox[ ItemBox[ PaneBox[ TagBox[#, "SkipImageSizeLevel"], Alignment -> {Center, Baseline}, BaselinePosition -> Baseline], DefaultBaseStyle -> "Labeled"], "SkipImageSizeLevel"], ItemBox[#2, DefaultBaseStyle -> "LabeledLabel"]}}, GridBoxAlignment -> {"Columns" -> {{Center}}, "Rows" -> {{Center}}}, AutoDelete -> False, GridBoxItemSize -> Automatic, BaselinePosition -> {1, 1}]& ), Editable->True, InterpretationFunction->(RowBox[{"Legended", "[", RowBox[{#, ",", RowBox[{"Placed", "[", RowBox[{#2, ",", "After"}], "]"}]}], "]"}]& )]], "Output", TaggingRules->{}, CellChangeTimes->{3.78033635756249*^9, 3.7803367665851593`*^9, 3.782464171853958*^9, 3.78265101390876*^9, 3.782652576659708*^9}, CellLabel->"Out[1]=", CellID->463868731] }, Open ]], Cell[CellGroupData[{ Cell[BoxData[ InterpretationBox[Cell["\t", "ExampleDelimiter"], $Line = 0; Null]], "ExampleDelimiter", TaggingRules->{}, CellID->14107562], Cell["\<\ Here is a quantile regression computation over a time series object:\ \>", "Text", TaggingRules->{}, CellChangeTimes->{{3.780335471782853*^9, 3.780335503755725*^9}, { 3.780335950534896*^9, 3.780335951085712*^9}, {3.7803369282457743`*^9, 3.7803369302810793`*^9}, {3.7824651944451523`*^9, 3.782465194803659*^9}, { 3.785786793082987*^9, 3.7857868007773275`*^9}, {3.786392584120894*^9, 3.7863926003947935`*^9}}, CellID->500081020], Cell[CellGroupData[{ Cell[BoxData[{ RowBox[{ RowBox[{"finData", "=", RowBox[{"FinancialData", "[", RowBox[{"\"\\"", ",", RowBox[{"{", RowBox[{ RowBox[{"{", RowBox[{"2010", ",", "1", ",", "1"}], "}"}], ",", RowBox[{"{", RowBox[{"2019", ",", "10", ",", "15"}], "}"}], ",", "\"\\""}], "}"}]}], "]"}]}], ";"}], "\n", RowBox[{ RowBox[{"qFunc", "=", RowBox[{"First", "@", RowBox[{"QuantileRegression", "[", RowBox[{"finData", ",", "12", ",", "0.5"}], "]"}]}]}], ";"}], "\[IndentingNewLine]", RowBox[{"DateListPlot", "[", RowBox[{ RowBox[{"{", RowBox[{"finData", ",", RowBox[{ RowBox[{ RowBox[{"{", RowBox[{"#", ",", RowBox[{"qFunc", "[", "#", "]"}]}], "}"}], "&"}], "/@", RowBox[{"finData", "[", "\"\\"", "]"}]}]}], "}"}], ",", RowBox[{"Joined", "\[Rule]", RowBox[{"{", RowBox[{"False", ",", "True"}], "}"}]}], ",", RowBox[{"PlotLegends", "\[Rule]", RowBox[{"{", RowBox[{"\"\