Skip to content

Commit

Permalink
Merge pull request #38 from africanmathsinitiative/master
Browse files Browse the repository at this point in the history
Fetching the latest copy
  • Loading branch information
stevenndungu authored Nov 14, 2016
2 parents cdb0d9a + 62c2d3a commit 14c5b43
Show file tree
Hide file tree
Showing 14 changed files with 179 additions and 81 deletions.
5 changes: 4 additions & 1 deletion instat/UcrGeomListWithAes.vb
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,11 @@ Public Class UcrGeomListWithParameters
End If
If clsCurrGeom.clsAesParameters(i).strIncludedDataTypes IsNot Nothing Then
lstAesParameterUcr(i).SetIncludedDataTypes(clsCurrGeom.clsAesParameters(i).strIncludedDataTypes)
ElseIf clsCurrGeom.clsAesParameters(i).strExcludedDataTypes IsNot Nothing Then
Else lstAesParameterUcr(i).RemoveIncludedMetadataProperty("class")
End If
If clsCurrGeom.clsAesParameters(i).strExcludedDataTypes IsNot Nothing Then
lstAesParameterUcr(i).SetExcludedDataTypes(clsCurrGeom.clsAesParameters(i).strExcludedDataTypes)
Else lstAesParameterUcr(i).RemoveExcludedMetadataProperty("class")
End If
Next
Else 'If the current geom has not been populated, then an error has been made in the code
Expand Down
4 changes: 2 additions & 2 deletions instat/clsRFunction.vb
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ Public Class RFunction

Public Event ParametersChanged()

Public Sub SetRCommand(strTemp As String)
strRCommand = strTemp
Public Sub SetRCommand(strTemp As String)
strRCommand = strTemp
bIsAssigned = False
End Sub

Expand Down
1 change: 1 addition & 0 deletions instat/dlgCombineforGraphics.vb
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ Public Class dlgCombineforGraphics
sdgCombineGraphOptions.SetRSyntax(ucrBase.clsRsyntax)
ucrBase.clsRsyntax.bExcludeAssignedFunctionOutput = False
ucrBase.clsRsyntax.SetFunction("gridExtra::grid.arrange")
ucrCombineGraphReceiver.strSelectorHeading = "Graphs"
End Sub

Private Sub SetDefaults()
Expand Down
32 changes: 15 additions & 17 deletions instat/dlgNon-ParametricOneWayANOVA.vb
Original file line number Diff line number Diff line change
Expand Up @@ -14,35 +14,38 @@
' You should have received a copy of the GNU General Public License k
' along with this program. If not, see <http://www.gnu.org/licenses/>.

Imports instat.Translations
Imports instat.Translations
Public Class dlgNon_ParametricOneWayANOVA

Public bFirstLoad As Boolean = True
Public clsModel As New ROperator

Private Sub dlgNon_ParametricOneWayANOVA_Load(sender As Object, e As EventArgs) Handles MyBase.Load

If bFirstLoad Then
InitializeDialog()
DefaultSettings()
InitialiseDialog()
SetDefaults()
bFirstLoad = False
Else
ReopenDialog()
End If



autoTranslate(Me)
End Sub
Private Sub InitializeDialog()

Private Sub InitialiseDialog()
ucrBase.clsRsyntax.SetFunction("kruskal.test")
ucrBase.clsRsyntax.iCallType = 2
ucrReceiverYVariate.Selector = ucrDataFrameAddRemove
ucrReceiverFactor.Selector = ucrDataFrameAddRemove
ucrReceiverFactor.SetDataType("factor")
clsModel.SetOperation("~")
autoTranslate(Me)
TestOKEnabled()
ucrBase.iHelpTopicID = 183
End Sub

Private Sub DefaultSettings()
Private Sub ReopenDialog()

End Sub

Private Sub SetDefaults()
ucrDataFrameAddRemove.Reset()
ucrDataFrameAddRemove.Focus()
ucrReceiverYVariate.SetMeAsReceiver()
Expand All @@ -56,14 +59,10 @@ Public Class dlgNon_ParametricOneWayANOVA

Private Sub ucrReceiverFactor_SelectionChanged(sender As Object, e As EventArgs) Handles ucrReceiverFactor.SelectionChanged
clsModel.SetParameter(False, strValue:=ucrReceiverFactor.GetVariableNames(bWithQuotes:=False))

TestOKEnabled()
End Sub



Private Sub TestOKEnabled()

If (Not ucrReceiverYVariate.IsEmpty()) And (Not ucrReceiverFactor.IsEmpty()) Then
ucrBase.clsRsyntax.AddParameter("formula", clsROperatorParameter:=clsModel)
ucrBase.OKEnabled(True)
Expand All @@ -78,7 +77,6 @@ Public Class dlgNon_ParametricOneWayANOVA
End Sub

Private Sub ucrBase_ClickReset(sender As Object, e As EventArgs) Handles ucrBase.ClickReset
DefaultSettings()
SetDefaults()
End Sub

End Class
4 changes: 2 additions & 2 deletions instat/dlgRegressionSimple.vb
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,12 @@ Public Class dlgRegressionSimple
ucrModelName.Reset()
ucrModelPreview.SetName("")
SetRCode()
TestOKEnabled()
DistributionsOffered()
sdgSimpleRegOptions.chkDisplayCLimits.Enabled = True
sdgSimpleRegOptions.lblDisplayCLevel.Enabled = True
sdgSimpleRegOptions.nudDisplayCLevel.Enabled = True
SetEnableDists()
TestOKEnabled()
End Sub

Private Sub LM()
Expand Down Expand Up @@ -254,8 +254,8 @@ Public Class dlgRegressionSimple
End Sub

Private Sub cmdDisplayOptions_Click(sender As Object, e As EventArgs) Handles cmdDisplayOptions.Click
sdgSimpleRegOptions.ShowDialog()
Display()
sdgSimpleRegOptions.ShowDialog()
End Sub

Public Sub ConvertToVariate()
Expand Down
13 changes: 2 additions & 11 deletions instat/dlgThreeVariablesModelling.vb
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,7 @@ Public Class dlgThreeVariableModelling
ucrResponse.Selector = ucrSelectorThreeVariableModelling
ucrFirstExplanatory.Selector = ucrSelectorThreeVariableModelling
ucrSecondExplanatory.Selector = ucrSelectorThreeVariableModelling
ucrModelOperator.cboInput.Items.Add("+")
ucrModelOperator.cboInput.Items.Add("*")
ucrModelOperator.cboInput.Items.Add(":")
ucrModelOperator.cboInput.Items.Add("/")
ucrModelOperator.SetItems({"+", "*", ":", "/"})
ucrFamily.SetGLMDistributions()
ucrModelName.SetDataFrameSelector(ucrSelectorThreeVariableModelling.ucrAvailableDataFrames)
ucrModelName.SetPrefix("reg")
Expand All @@ -63,8 +60,6 @@ Public Class dlgThreeVariableModelling
sdgModelOptions.SetRCIFunction(clsRCIFunction)
sdgVariableTransformations.SetRCIFunction(clsRCIFunction)
AssignModelName()
ModelOperator()
TestOKEnabled()
ucrModelName.SetValidationTypeAsRVariable()
End Sub

Expand Down Expand Up @@ -94,10 +89,10 @@ Public Class dlgThreeVariableModelling
ucrModelPreview.Reset()
ResponseConvert()
ModelOperator()
TestOKEnabled()
sdgSimpleRegOptions.chkDisplayCLimits.Enabled = True
sdgSimpleRegOptions.lblDisplayCLevel.Enabled = True
sdgSimpleRegOptions.nudDisplayCLevel.Enabled = True
TestOKEnabled()
End Sub

Public Sub TestOKEnabled()
Expand All @@ -116,10 +111,6 @@ Public Class dlgThreeVariableModelling
AssignModelName()
End Sub

Private Sub cmdRegressionOptions_Click(sender As Object, e As EventArgs) Handles cmdDisplayOptions.Click
sdgSimpleRegOptions.ShowDialog()
End Sub

Public Sub ResponseConvert()
If Not ucrResponse.IsEmpty Then
ucrFamily.RecieverDatatype(ucrSelectorThreeVariableModelling.ucrAvailableDataFrames.cboAvailableDataFrames.Text, ucrResponse.GetVariableNames(bWithQuotes:=False))
Expand Down
1 change: 1 addition & 0 deletions instat/dlgTwoVariableUseModel.vb
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ Public Class dlgTwoVariableUseModel
ucrModel.IsReadOnly = True
sdgSimpleRegOptions.SetRModelFunction(clsRCommand)
sdgSimpleRegOptions.SetRDataFrame(ucrSelectorUseModel.ucrAvailableDataFrames)
ucrReceiverUseModel.strSelectorHeading = "Models"
End Sub

Private Sub ReOpenDialog()
Expand Down
1 change: 1 addition & 0 deletions instat/dlgUseGraph.vb
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ Public Class dlgUseGraph
ucrSaveGraphForUseGraph.SetDataFrameSelector(ucrGraphsSelector.ucrAvailableDataFrames)
ucrBase.clsRsyntax.bExcludeAssignedFunctionOutput = False
sdgPlots.SetRSyntax(ucrBase.clsRsyntax)
ucrGraphReceiver.strSelectorHeading = "Graphs"
End Sub
Private Sub ReOpenDialog()

Expand Down
14 changes: 7 additions & 7 deletions instat/sdgLayerOptions.Designer.vb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 14c5b43

Please sign in to comment.