You've already forked lazarus-ccr
LazStats: Fine-tuning and chm help file update of CrossTabUnit and BreakdownUnit
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@8026 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
Binary file not shown.
Binary file not shown.
@ -196,7 +196,7 @@
|
||||
<Unit10>
|
||||
<Filename Value="forms\analysis\descriptive\descriptiveunit.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<ComponentName Value="DescriptiveFrm"/>
|
||||
<ComponentName Value="DescriptiveForm"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="DescriptiveUnit"/>
|
||||
@ -220,7 +220,7 @@
|
||||
<Unit13>
|
||||
<Filename Value="forms\analysis\descriptive\crosstabunit.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<ComponentName Value="CrossTabFrm"/>
|
||||
<ComponentName Value="CrossTabForm"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="CrossTabUnit"/>
|
||||
@ -233,7 +233,7 @@
|
||||
<Unit15>
|
||||
<Filename Value="forms\analysis\descriptive\breakdownunit.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<ComponentName Value="BreakDownFrm"/>
|
||||
<ComponentName Value="BreakDownForm"/>
|
||||
<HasResources Value="True"/>
|
||||
<ResourceBaseClass Value="Form"/>
|
||||
<UnitName Value="BreakDownUnit"/>
|
||||
|
@ -1,56 +1,60 @@
|
||||
inherited BreakDownFrm: TBreakDownFrm
|
||||
inherited BreakDownForm: TBreakDownForm
|
||||
Left = 400
|
||||
Height = 363
|
||||
Height = 287
|
||||
Top = 248
|
||||
Width = 873
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/Breakdown.htm'
|
||||
Caption = 'Breakdown'
|
||||
ClientHeight = 363
|
||||
ClientHeight = 287
|
||||
ClientWidth = 873
|
||||
inherited ParamsPanel: TPanel
|
||||
Height = 347
|
||||
Height = 271
|
||||
Width = 344
|
||||
ClientHeight = 347
|
||||
ClientHeight = 271
|
||||
ClientWidth = 344
|
||||
inherited CloseBtn: TButton
|
||||
Left = 289
|
||||
Top = 322
|
||||
Top = 246
|
||||
TabOrder = 11
|
||||
end
|
||||
inherited ComputeBtn: TButton
|
||||
Left = 205
|
||||
Top = 322
|
||||
Top = 246
|
||||
TabOrder = 10
|
||||
end
|
||||
inherited ResetBtn: TButton
|
||||
Left = 143
|
||||
Top = 322
|
||||
Top = 246
|
||||
TabOrder = 9
|
||||
end
|
||||
inherited HelpBtn: TButton
|
||||
Left = 84
|
||||
Top = 322
|
||||
Top = 246
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/Breakdown.htm'
|
||||
TabOrder = 8
|
||||
end
|
||||
inherited ButtonBevel: TBevel
|
||||
Top = 306
|
||||
Top = 230
|
||||
Width = 344
|
||||
end
|
||||
object CheckGroup1: TCheckGroup[5]
|
||||
AnchorSideLeft.Control = ParamsPanel
|
||||
AnchorSideLeft.Control = DepVar
|
||||
AnchorSideTop.Control = SelVarOutBtn
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = ParamsPanel
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = ButtonBevel
|
||||
Left = 0
|
||||
AnchorSideBottom.Control = VarList
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 194
|
||||
Height = 51
|
||||
Top = 255
|
||||
Width = 140
|
||||
Anchors = [akLeft, akBottom]
|
||||
Top = 179
|
||||
Width = 150
|
||||
Anchors = [akLeft, akRight, akBottom]
|
||||
AutoFill = True
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 8
|
||||
BorderSpacing.Right = 8
|
||||
Caption = 'Option'
|
||||
ChildSizing.LeftRightSpacing = 12
|
||||
ChildSizing.TopBottomSpacing = 6
|
||||
@ -61,7 +65,7 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||
ChildSizing.ControlsPerLine = 1
|
||||
ClientHeight = 31
|
||||
ClientWidth = 136
|
||||
ClientWidth = 146
|
||||
Items.Strings = (
|
||||
'One Way ANOVA'
|
||||
)
|
||||
@ -95,7 +99,7 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
AnchorSideBottom.Control = DepVar
|
||||
Left = 194
|
||||
Height = 15
|
||||
Top = 195
|
||||
Top = 119
|
||||
Width = 153
|
||||
Anchors = [akLeft, akBottom]
|
||||
BorderSpacing.Bottom = 2
|
||||
@ -107,9 +111,9 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
AnchorSideTop.Control = AvailLabel
|
||||
AnchorSideTop.Side = asrBottom
|
||||
AnchorSideRight.Control = InBtn
|
||||
AnchorSideBottom.Control = CheckGroup1
|
||||
AnchorSideBottom.Control = ButtonBevel
|
||||
Left = 0
|
||||
Height = 230
|
||||
Height = 213
|
||||
Top = 17
|
||||
Width = 150
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
@ -130,7 +134,7 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
AnchorSideRight.Side = asrBottom
|
||||
AnchorSideBottom.Control = SelVarInBtn
|
||||
Left = 194
|
||||
Height = 162
|
||||
Height = 86
|
||||
Top = 17
|
||||
Width = 150
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
@ -152,7 +156,7 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 194
|
||||
Height = 23
|
||||
Top = 212
|
||||
Top = 136
|
||||
Width = 150
|
||||
Anchors = [akLeft, akRight, akBottom]
|
||||
BorderSpacing.Top = 2
|
||||
@ -197,7 +201,7 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
AnchorSideBottom.Control = SelVarOutBtn
|
||||
Left = 158
|
||||
Height = 28
|
||||
Top = 187
|
||||
Top = 111
|
||||
Width = 28
|
||||
Anchors = [akLeft, akBottom]
|
||||
BorderSpacing.Bottom = 4
|
||||
@ -210,11 +214,10 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
object SelVarOutBtn: TBitBtn[15]
|
||||
AnchorSideLeft.Control = ParamsPanel
|
||||
AnchorSideLeft.Side = asrCenter
|
||||
AnchorSideBottom.Control = VarList
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
AnchorSideBottom.Control = CheckGroup1
|
||||
Left = 158
|
||||
Height = 28
|
||||
Top = 219
|
||||
Top = 143
|
||||
Width = 28
|
||||
Anchors = [akLeft, akBottom]
|
||||
Images = MainDataModule.ImageList
|
||||
@ -226,11 +229,11 @@ inherited BreakDownFrm: TBreakDownFrm
|
||||
end
|
||||
inherited ParamsSplitter: TSplitter
|
||||
Left = 356
|
||||
Height = 363
|
||||
Height = 287
|
||||
end
|
||||
object PageControl: TPageControl[2]
|
||||
Left = 365
|
||||
Height = 347
|
||||
Height = 271
|
||||
Top = 8
|
||||
Width = 500
|
||||
ActivePage = BreakDownPage
|
||||
|
@ -13,9 +13,9 @@ uses
|
||||
|
||||
type
|
||||
|
||||
{ TBreakDownFrm }
|
||||
{ TBreakDownForm }
|
||||
|
||||
TBreakDownFrm = class(TBasicStatsReportForm)
|
||||
TBreakDownForm = class(TBasicStatsReportForm)
|
||||
InBtn: TBitBtn;
|
||||
OutBtn: TBitBtn;
|
||||
PageControl: TPageControl;
|
||||
@ -52,6 +52,7 @@ type
|
||||
procedure AdjustConstraints; override;
|
||||
procedure Compute; override;
|
||||
procedure UpdateBtnStates; override;
|
||||
function Validate(out AMsg: String; out AControl: TWinControl): Boolean; override;
|
||||
|
||||
public
|
||||
constructor Create(AOwner: TComponent); override;
|
||||
@ -59,7 +60,7 @@ type
|
||||
end;
|
||||
|
||||
var
|
||||
BreakDownFrm: TBreakDownFrm;
|
||||
BreakDownForm: TBreakDownForm;
|
||||
|
||||
|
||||
|
||||
@ -69,22 +70,28 @@ implementation
|
||||
|
||||
uses
|
||||
Math,
|
||||
Utils, MathUnit;
|
||||
Utils, MathUnit, GridProcs;
|
||||
|
||||
|
||||
{ TBreakDownFrm }
|
||||
{ TBreakDownForm }
|
||||
|
||||
constructor TBreakDownFrm.Create(AOwner: TComponent);
|
||||
constructor TBreakDownForm.Create(AOwner: TComponent);
|
||||
begin
|
||||
inherited;
|
||||
|
||||
FReportFrame.Parent := BreakDownPage;
|
||||
FReportFrame.BorderSpacing.Left := 0;
|
||||
FReportFrame.BorderSpacing.Top := 0;
|
||||
FReportFrame.BorderSpacing.Bottom := 0;
|
||||
FReportFrame.BorderSpacing.Right := 0;
|
||||
InitToolbar(FReportFrame.ReportToolbar, tpTop);
|
||||
|
||||
FANOVAReportFrame := TReportFrame.Create(ANOVAPage);
|
||||
with FANOVAReportFrame do
|
||||
begin
|
||||
Parent := ANOVAPage;
|
||||
Align := alClient;
|
||||
// InitToolbar(ReportToolbar, tpRight);
|
||||
end;
|
||||
|
||||
PageControl.ActivePage := BreakdownPage;
|
||||
@ -93,7 +100,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.AdjustConstraints;
|
||||
procedure TBreakDownForm.AdjustConstraints;
|
||||
begin
|
||||
inherited;
|
||||
|
||||
@ -101,18 +108,13 @@ begin
|
||||
4*CloseBtn.Width + 3*CloseBtn.BorderSpacing.Left,
|
||||
SelLabel.Width * 2 + InBtn.Width + VarList.BorderSpacing.Right * 2);
|
||||
ParamsPanel.Constraints.MinHeight := InBtn.Top +
|
||||
4*InBtn.Height + 3*OutBtn.BorderSpacing.Bottom +
|
||||
4*InBtn.Height + 3*OutBtn.BorderSpacing.Top +
|
||||
CheckGroup1.BorderSpacing.Top + CheckGroup1.Height + ButtonBevel.Height +
|
||||
CloseBtn.BorderSpacing.Top + CloseBtn.Height;
|
||||
|
||||
Constraints.MinWidth := ParamsPanel.Constraints.MinWidth + 300;
|
||||
Constraints.MinHeight := ParamsPanel.Constraints.MinHeight + ParamsPanel.BorderSpacing.Left*2;
|
||||
if Width < Constraints.MinWidth then Width := 1; // enforce constraints
|
||||
if Height < Constraints.MinHeight then Height := 1;
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.ANOVA(ListSize: Integer; Freq, Selected, Minimum,
|
||||
procedure TBreakDownForm.ANOVA(ListSize: Integer; Freq, Selected, Minimum,
|
||||
Subscript, Levels, Displace: IntDyneVec; Mean, SS: DblDyneVec; AReport: TStrings);
|
||||
var
|
||||
i, j: Integer;
|
||||
@ -277,7 +279,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.Compute;
|
||||
procedure TBreakDownForm.Compute;
|
||||
label
|
||||
Label1, Label3, Label4, NextStep;
|
||||
var
|
||||
@ -312,19 +314,9 @@ begin
|
||||
// Identify columns of variables to analyze and the dependent var.
|
||||
NoSelected := SelList.Items.Count;
|
||||
|
||||
if NoSelected = 0 then
|
||||
begin
|
||||
ErrorMsg('No variables selected.');
|
||||
exit;
|
||||
end;
|
||||
|
||||
// Get column no. of dependent variable
|
||||
dependentVar := 0;
|
||||
cellstring := DepVar.Text;
|
||||
for i := 1 to NoVariables do
|
||||
if cellstring = OS3MainFrm.DataGrid.Cells[i,0] then dependentvar := i;
|
||||
|
||||
if dependentVar = 0 then
|
||||
dependentVar := GetVariableIndex(OS3MainFrm.DataGrid, DepVar.Text);
|
||||
if dependentVar = -1 then
|
||||
begin
|
||||
ErrorMsg('Continuous variable is not specified.');
|
||||
exit;
|
||||
@ -332,12 +324,8 @@ begin
|
||||
|
||||
// Get selected variables
|
||||
SetLength(selected, NoVariables);
|
||||
for i := 1 to NoSelected do
|
||||
begin
|
||||
cellstring := SelList.Items[i-1];
|
||||
for j := 1 to NoVariables do
|
||||
if cellstring = OS3MainFrm.DataGrid.Cells[j,0] then Selected[i-1] := j;
|
||||
end;
|
||||
for i := 0 to NoSelected-1 do
|
||||
Selected[i] := GetVariableIndex(OS3MainFrm.DataGrid, SelList.Items[i]);
|
||||
Selected[NoSelected] := dependentvar;
|
||||
ListSize := NoSelected;
|
||||
|
||||
@ -377,7 +365,7 @@ begin
|
||||
for i := 1 to NoCases do
|
||||
begin
|
||||
dataread := false;
|
||||
if GoodRecord(i, NoSelected, Selected) then
|
||||
if DataProcs.GoodRecord(i, NoSelected, Selected) then
|
||||
begin
|
||||
for j := 1 to ListSize do
|
||||
begin
|
||||
@ -556,7 +544,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.GetLevels(const AMinimum, AMaximum, ALevels, ADisplace: IntDyneVec);
|
||||
procedure TBreakDownForm.GetLevels(const AMinimum, AMaximum, ALevels, ADisplace: IntDyneVec);
|
||||
var
|
||||
i: Integer;
|
||||
listSize: Integer;
|
||||
@ -574,7 +562,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.GetMinMax(const AMinimum, AMaximum, ASelected: IntDyneVec);
|
||||
procedure TBreakDownForm.GetMinMax(const AMinimum, AMaximum, ASelected: IntDyneVec);
|
||||
var
|
||||
i, j, index: Integer;
|
||||
listSize: Integer;
|
||||
@ -591,7 +579,7 @@ begin
|
||||
AMaximum[i] := AMinimum[i];
|
||||
for j := 1 to NoCases do
|
||||
begin
|
||||
if GoodRecord(j, NoSelected, ASelected) then
|
||||
if DataProcs.GoodRecord(j, NoSelected, ASelected) then
|
||||
begin
|
||||
X := round(StrToFloat(OS3MainFrm.DataGrid.Cells[index, j]));
|
||||
if X < AMinimum[i] then AMinimum[i] := X;
|
||||
@ -602,7 +590,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.InBtnClick(Sender: TObject);
|
||||
procedure TBreakDownForm.InBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -620,8 +608,7 @@ begin
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
||||
|
||||
function TBreakDownFrm.Index_Pos(const X, ADisplace: IntDyneVec;
|
||||
function TBreakDownForm.Index_Pos(const X, ADisplace: IntDyneVec;
|
||||
AListSize: integer): integer;
|
||||
var
|
||||
i: integer;
|
||||
@ -632,7 +619,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.OutBtnClick(Sender: TObject);
|
||||
procedure TBreakDownForm.OutBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -651,21 +638,17 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.Reset;
|
||||
var
|
||||
i: integer;
|
||||
procedure TBreakDownForm.Reset;
|
||||
begin
|
||||
inherited;
|
||||
|
||||
VarList.Clear;
|
||||
SelList.Clear;
|
||||
DepVar.Text := '';
|
||||
InBtn.Enabled := true;
|
||||
OutBtn.Enabled := false;
|
||||
SelVarInBtn.Enabled := true;
|
||||
SelVarOutBtn.Enabled := false;
|
||||
for i := 1 to NoVariables do
|
||||
VarList.Items.Add(OS3MainFrm.DataGrid.Cells[i,0]);
|
||||
CollectVariableNames(OS3MainFrm.DataGrid, VarList.Items);
|
||||
SelList.Clear;
|
||||
|
||||
if FAnovaReportFrame <> nil then
|
||||
FAnovaReportFrame.Clear;
|
||||
@ -677,7 +660,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.SelListDblClick(Sender: TObject);
|
||||
procedure TBreakDownForm.SelListDblClick(Sender: TObject);
|
||||
var
|
||||
index: Integer;
|
||||
begin
|
||||
@ -691,13 +674,13 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.SelListSelectionChange(Sender: TObject; User: boolean);
|
||||
procedure TBreakDownForm.SelListSelectionChange(Sender: TObject; User: boolean);
|
||||
begin
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.SelVarInBtnClick(Sender: TObject);
|
||||
procedure TBreakDownForm.SelVarInBtnClick(Sender: TObject);
|
||||
var
|
||||
index : integer;
|
||||
begin
|
||||
@ -711,7 +694,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.SelVarOutBtnClick(Sender: TObject);
|
||||
procedure TBreakDownForm.SelVarOutBtnClick(Sender: TObject);
|
||||
begin
|
||||
if DepVar.Text <> '' then
|
||||
VarList.Items.Add(DepVar.Text);
|
||||
@ -719,7 +702,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.UpdateBtnStates;
|
||||
procedure TBreakDownForm.UpdateBtnStates;
|
||||
var
|
||||
lSelected: Boolean;
|
||||
i: Integer;
|
||||
@ -750,7 +733,22 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.VarListDblClick(Sender: TObject);
|
||||
function TBreakDownForm.Validate(out AMsg: String; out AControl: TWinControl): Boolean;
|
||||
begin
|
||||
Result := false;
|
||||
|
||||
if SelList.Items.Count = 0 then
|
||||
begin
|
||||
AMsg := 'No variables selected.';
|
||||
AControl := SelList;
|
||||
exit;
|
||||
end;
|
||||
|
||||
Result := true;
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownForm.VarListDblClick(Sender: TObject);
|
||||
var
|
||||
index: Integer;
|
||||
begin
|
||||
@ -764,7 +762,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TBreakDownFrm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
procedure TBreakDownForm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
begin
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
@ -1,10 +1,10 @@
|
||||
inherited CrossTabFrm: TCrossTabFrm
|
||||
inherited CrossTabForm: TCrossTabForm
|
||||
Left = 459
|
||||
Height = 358
|
||||
Top = 230
|
||||
Width = 879
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/Cross-tabulation.htm'
|
||||
HelpKeyword = 'html/CrossTabulation.htm'
|
||||
Caption = 'Cross Tabulation'
|
||||
ClientHeight = 358
|
||||
ClientWidth = 879
|
||||
@ -31,6 +31,8 @@ inherited CrossTabFrm: TCrossTabFrm
|
||||
inherited HelpBtn: TButton
|
||||
Left = 60
|
||||
Top = 317
|
||||
HelpType = htKeyword
|
||||
HelpKeyword = 'html/CrossTabulation.htm'
|
||||
TabOrder = 4
|
||||
end
|
||||
inherited ButtonBevel: TBevel
|
||||
|
@ -13,9 +13,9 @@ uses
|
||||
|
||||
type
|
||||
|
||||
{ TCrossTabFrm }
|
||||
{ TCrossTabForm }
|
||||
|
||||
TCrossTabFrm = class(TBasicStatsReportForm)
|
||||
TCrossTabForm = class(TBasicStatsReportForm)
|
||||
VertCenterBevel: TBevel;
|
||||
InBtn: TBitBtn;
|
||||
OutBtn: TBitBtn;
|
||||
@ -36,13 +36,14 @@ type
|
||||
procedure AdjustConstraints; override;
|
||||
procedure Compute; override;
|
||||
procedure UpdateBtnStates; override;
|
||||
function Validate(out AMsg: String; out AControl: TWinControl): Boolean; override;
|
||||
|
||||
public
|
||||
procedure Reset; override;
|
||||
end;
|
||||
|
||||
var
|
||||
CrossTabFrm: TCrossTabFrm;
|
||||
CrossTabForm: TCrossTabForm;
|
||||
|
||||
|
||||
implementation
|
||||
@ -299,9 +300,9 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
{ TCrossTabFrm }
|
||||
{ TCrossTabForm }
|
||||
|
||||
procedure TCrossTabFrm.AdjustConstraints;
|
||||
procedure TCrossTabForm.AdjustConstraints;
|
||||
begin
|
||||
inherited;
|
||||
|
||||
@ -313,7 +314,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.Compute;
|
||||
procedure TCrossTabForm.Compute;
|
||||
var
|
||||
lReport: TStringList;
|
||||
crossTab: TCrossTabCalculator;
|
||||
@ -322,12 +323,6 @@ var
|
||||
begin
|
||||
inherited;
|
||||
|
||||
if SelList.Items.Count = 0 then
|
||||
begin
|
||||
ErrorMsg('No variables selected for analysis.');
|
||||
exit;
|
||||
end;
|
||||
|
||||
lReport := TStringList.Create;
|
||||
try
|
||||
lReport.Add('CROSSTAB RESULTS');
|
||||
@ -349,7 +344,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.InBtnClick(Sender: TObject);
|
||||
procedure TCrossTabForm.InBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -368,7 +363,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.OutBtnClick(Sender: TObject);
|
||||
procedure TCrossTabForm.OutBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -387,7 +382,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.Prepare(out AVarlist, AColNoSelected: IntDyneVec);
|
||||
procedure TCrossTabForm.Prepare(out AVarlist, AColNoSelected: IntDyneVec);
|
||||
var
|
||||
i, j: Integer;
|
||||
noSelected: Integer;
|
||||
@ -420,21 +415,17 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.Reset;
|
||||
var
|
||||
i: integer;
|
||||
procedure TCrossTabForm.Reset;
|
||||
begin
|
||||
inherited;
|
||||
|
||||
VarList.Clear;
|
||||
CollectVariableNames(OS3MainFrm.DataGrid, VarList.Items);
|
||||
SelList.Clear;
|
||||
for i := 1 to NoVariables do
|
||||
VarList.Items.Add(OS3MainFrm.DataGrid.Cells[i,0]);
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.SelListDblClick(Sender: TObject);
|
||||
procedure TCrossTabForm.SelListDblClick(Sender: TObject);
|
||||
var
|
||||
index: Integer;
|
||||
begin
|
||||
@ -448,7 +439,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.UpdateBtnStates;
|
||||
procedure TCrossTabForm.UpdateBtnStates;
|
||||
var
|
||||
lSelected: Boolean;
|
||||
i: Integer;
|
||||
@ -475,7 +466,23 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.VarListDblClick(Sender: TObject);
|
||||
function TCrossTabForm.Validate(out AMsg: String;
|
||||
out AControl: TWinControl): Boolean;
|
||||
begin
|
||||
Result := false;
|
||||
|
||||
if SelList.Items.Count = 0 then
|
||||
begin
|
||||
AMsg := 'No variables selected for analysis.';
|
||||
AControl := SelList;
|
||||
exit;
|
||||
end;
|
||||
|
||||
Result := true;
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabForm.VarListDblClick(Sender: TObject);
|
||||
var
|
||||
index: Integer;
|
||||
begin
|
||||
@ -489,7 +496,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TCrossTabFrm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
procedure TCrossTabForm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
begin
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
@ -1,4 +1,4 @@
|
||||
inherited DescriptiveFrm: TDescriptiveFrm
|
||||
inherited DescriptiveForm: TDescriptiveForm
|
||||
Left = 526
|
||||
Height = 432
|
||||
Top = 202
|
||||
|
@ -63,9 +63,9 @@ type
|
||||
end;
|
||||
|
||||
|
||||
{ TDescriptiveFrm }
|
||||
{ TDescriptiveForm }
|
||||
|
||||
TDescriptiveFrm = class(TBasicStatsReportForm)
|
||||
TDescriptiveForm = class(TBasicStatsReportForm)
|
||||
CaseChk: TCheckBox;
|
||||
DecPlacesEdit: TSpinEdit;
|
||||
Label4: TLabel;
|
||||
@ -108,7 +108,7 @@ type
|
||||
end;
|
||||
|
||||
var
|
||||
DescriptiveFrm: TDescriptiveFrm;
|
||||
DescriptiveForm: TDescriptiveForm;
|
||||
|
||||
|
||||
implementation
|
||||
@ -339,9 +339,9 @@ end;
|
||||
|
||||
|
||||
|
||||
{ TDescriptiveFrm }
|
||||
{ TDescriptiveForm }
|
||||
|
||||
constructor TDescriptiveFrm.Create(AOwner: TComponent);
|
||||
constructor TDescriptiveForm.Create(AOwner: TComponent);
|
||||
begin
|
||||
inherited;
|
||||
FReportFrame.Parent := ReportPage;
|
||||
@ -352,7 +352,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.AdjustConstraints;
|
||||
procedure TDescriptiveForm.AdjustConstraints;
|
||||
begin
|
||||
ParamsPanel.Constraints.MinHeight := AllBtn.Top + AllBtn.Height + OptionsGroup.Height +
|
||||
CIEdit.Height + ButtonBevel.Height + CloseBtn.Height + VarList.BorderSpacing.Bottom +
|
||||
@ -366,7 +366,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.AllBtnClick(Sender: TObject);
|
||||
procedure TDescriptiveForm.AllBtnClick(Sender: TObject);
|
||||
var
|
||||
i : integer;
|
||||
begin
|
||||
@ -377,7 +377,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.Compute;
|
||||
procedure TDescriptiveForm.Compute;
|
||||
var
|
||||
i: Integer;
|
||||
nSelected: Integer;
|
||||
@ -452,7 +452,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
function TDescriptiveFrm.GetReportFrame(APageIndex: Integer): TReportFrame;
|
||||
function TDescriptiveForm.GetReportFrame(APageIndex: Integer): TReportFrame;
|
||||
var
|
||||
page: TTabSheet;
|
||||
begin
|
||||
@ -466,7 +466,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.InBtnClick(Sender: TObject);
|
||||
procedure TDescriptiveForm.InBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -485,7 +485,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.OutBtnClick(Sender: TObject);
|
||||
procedure TDescriptiveForm.OutBtnClick(Sender: TObject);
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -504,7 +504,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.Reset;
|
||||
procedure TDescriptiveForm.Reset;
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
@ -523,7 +523,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.SelListDblClick(Sender: TObject);
|
||||
procedure TDescriptiveForm.SelListDblClick(Sender: TObject);
|
||||
var
|
||||
index: integer;
|
||||
begin
|
||||
@ -537,7 +537,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.VarListDblClick(Sender: TObject);
|
||||
procedure TDescriptiveForm.VarListDblClick(Sender: TObject);
|
||||
var
|
||||
index: integer;
|
||||
begin
|
||||
@ -551,7 +551,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.UpdateBtnStates;
|
||||
procedure TDescriptiveForm.UpdateBtnStates;
|
||||
var
|
||||
lSelected: Boolean;
|
||||
i: Integer;
|
||||
@ -580,13 +580,13 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
procedure TDescriptiveForm.VarListSelectionChange(Sender: TObject; User: boolean);
|
||||
begin
|
||||
UpdateBtnStates;
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.WriteToReport(Stats: TDescriptiveStats;
|
||||
procedure TDescriptiveForm.WriteToReport(Stats: TDescriptiveStats;
|
||||
AVarName: String; AReport: TStrings);
|
||||
var
|
||||
w: Integer;
|
||||
@ -683,7 +683,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
procedure TDescriptiveFrm.zScoresToGrid(AColIndex: Integer;
|
||||
procedure TDescriptiveForm.zScoresToGrid(AColIndex: Integer;
|
||||
var AColsSelected: IntDyneVec; AMean, AStdDev: Double);
|
||||
var
|
||||
i, idx: Integer;
|
||||
|
@ -1904,9 +1904,9 @@ end;
|
||||
// Menu "Analysis" > "Descriptive" > "reakdown"
|
||||
procedure TOS3MainFrm.mnuAnalysisDescr_BreakdownClick(Sender: TObject);
|
||||
begin
|
||||
if BreakDownFrm = nil then
|
||||
Application.CreateForm(TBreakDownFrm, BreakDownFrm);
|
||||
BreakDownFrm.Show;
|
||||
if BreakDownForm = nil then
|
||||
Application.CreateForm(TBreakDownForm, BreakDownForm);
|
||||
BreakDownForm.Show;
|
||||
end;
|
||||
|
||||
// Menu "Analysis" > "Descriptive" > "Repeated Measures Bubble Plot"
|
||||
@ -1928,9 +1928,9 @@ end;
|
||||
// Menu "Analysis" > "Descriptive" > "Cross tabulation"
|
||||
procedure TOS3MainFrm.mnuAnalysisDescr_CrossTabsClick(Sender: TObject);
|
||||
begin
|
||||
if CrossTabFrm = nil then
|
||||
Application.CreateForm(TCrossTabFrm, CrossTabFrm);
|
||||
CrossTabFrm.Show;
|
||||
if CrossTabForm = nil then
|
||||
Application.CreateForm(TCrossTabForm, CrossTabForm);
|
||||
CrossTabForm.Show;
|
||||
end;
|
||||
|
||||
// Menu "Analysis" > "Descriptive" > "Data Smoothing"
|
||||
@ -1944,9 +1944,9 @@ end;
|
||||
// Menu "Analysis" > "Descriptive" > "Distribution Statistics"
|
||||
procedure TOS3MainFrm.mnuAnalysisDescr_DistribStatsClick(Sender: TObject);
|
||||
begin
|
||||
if DescriptiveFrm = nil then
|
||||
Application.CreateForm(TDescriptiveFrm, DescriptiveFrm);
|
||||
DescriptiveFrm.Show;
|
||||
if DescriptiveForm = nil then
|
||||
Application.CreateForm(TDescriptiveForm, DescriptiveForm);
|
||||
DescriptiveForm.Show;
|
||||
end;
|
||||
|
||||
// Menu "Analysis" > "Descriptive" > "Frequency Analysis"
|
||||
|
Reference in New Issue
Block a user