192
Example 11
Modeling in VB.NET
Model A
The following program fits Model A. It is saved as Ex11-a.vb.
Sub Main()
Dim Sem As New AmosEngine
Try
Sem.TextOutput()
Sem.BeginGroup(Sem.AmosDir & "Examples\Fels_fem.sav")
Sem.GroupName("girls")
Sem.AStructure("academic = GPA + attract + error1 (1)")
Sem.AStructure _
("attract = height + weight + rating + academic + error2 (1)")
Sem.AStructure("error2 <--> error1")
Sem.BeginGroup(Sem.AmosDir & "Examples\Fels_mal.sav")
Sem.GroupName("boys")
Sem.AStructure("academic = GPA + attract + error1 (1)")
Sem.AStructure _
("attract = height + weight + rating + academic + error2 (1)")
Sem.AStructure("error2 <--> error1")
Sem.FitModel()
Finally
Sem.Dispose()
End Try
End Sub