Version 5.2.6.1, tag libreoffice-5.2.6.1
[LibreOffice.git] / sc / source / ui / inc / AnalysisOfVarianceDialog.hxx
blob0b00ab464beae50c0048c2b422a3ab25690e9b41
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 */
11 #ifndef INCLUDED_SC_SOURCE_UI_INC_ANALYSISOFVARIANCEDIALOG_HXX
12 #define INCLUDED_SC_SOURCE_UI_INC_ANALYSISOFVARIANCEDIALOG_HXX
14 #include "global.hxx"
15 #include "address.hxx"
16 #include "anyrefdg.hxx"
18 #include <vcl/fixed.hxx>
19 #include <vcl/group.hxx>
20 #include <vcl/lstbox.hxx>
22 #include "StatisticsInputOutputDialog.hxx"
24 class FormulaTemplate;
25 class AddressWalkerWriter;
27 class ScAnalysisOfVarianceDialog : public ScStatisticsInputOutputDialog
29 private:
30 enum AnovaFactor
32 SINGLE_FACTOR,
33 TWO_FACTOR
36 VclPtr<NumericField> mpAlphaField;
37 VclPtr<RadioButton> mpSingleFactorRadio;
38 VclPtr<RadioButton> mpTwoFactorRadio;
39 VclPtr<NumericField> mpRowsPerSampleField;
41 DECL_LINK_TYPED(FactorChanged, RadioButton&, void);
42 void FactorChanged();
44 AnovaFactor meFactor;
46 static void RowColumn(ScRangeList& rRangeList, AddressWalkerWriter& aOutput,
47 FormulaTemplate& aTemplate, OUString& sFormula,
48 GroupedBy aGroupedBy, ScRange* pResultRange);
50 void AnovaSingleFactor(AddressWalkerWriter& output, FormulaTemplate& aTemplate);
51 void AnovaTwoFactor(AddressWalkerWriter& output, FormulaTemplate& aTemplate);
53 public:
54 ScAnalysisOfVarianceDialog(
55 SfxBindings* pB, SfxChildWindow* pCW,
56 vcl::Window* pParent, ScViewData* pViewData );
58 virtual ~ScAnalysisOfVarianceDialog();
59 virtual void dispose() override;
61 virtual bool Close() override;
63 protected:
64 virtual sal_Int16 GetUndoNameId() override;
65 virtual ScRange ApplyOutput(ScDocShell* pDocShell) override;
68 #endif
70 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */