Economic,
Environmental,
and
Benefits
Analysis
of
the
Final
Metal
Products
and
Machinery
Rule
Programs
and
Output
Tables
for
the
Ohio
RUM
Model
February
14,
2003
Prepared
for:
U.
S.
Environmental
Protection
Agency
Office
of
Science
and
Technology
Engineering
and
Analysis
Division
401
M
Street,
S.
W.
Washington,
D.
C.
20460
Dr.
Lynne
Tudor
Task
Manager
2
Programs
and
Output
Tables
for
the
Ohio
RUM
Model
Random
Utility
Model
Programs
and
Data
Sets
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
3
Estimation
of
the
Site
Choice
Models
of
Recreation
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
10
Generate
Participant
Data
Sets
with
Randomly
Drawn
Choice
Sets
.
.
.
.
.
.
.
.
.
.
11
"
Fishing
Model
­
with
Out
of
state
WBType
Split.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
12
"
Boating
Model
Glake
Split
3_
20_
02.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
24
"
Viewing
Model
3_
19_
02.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
35
"
Swimming
Model
Glake
Split
3_
20_
02.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
46
Estimate
the
Site
Choice
Models
in
Limdep
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
57
"
Run
Random
Fish
Draws.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
58
"
Run
Random
Draws
for
Boating.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
73
"
Run
Random
Draws
for
Viewing
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
87
"
Run
Random
Draws
for
Swimming
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
96
"
Random
Draw
Parameter
Analysis
for
Revised
Models.
xls"
.
.
.
.
.
.
.
110
Estimation
of
the
Participation
Models
of
Recreation
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
111
Generate
Data
Sets
of
Participants
and
Non­
participants
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
112
"
Fishing
IV
Calculation.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
113
"
Boating
IV
Calculation.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
117
"
Viewing
IV
Calculation.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
121
"
Swimming
IV
Calculation.
sas"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
125
Estimate
the
Trip
Participation
Models
in
Limdep
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
129
"
Fishing
Trip
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
130
"
Boating
Trip
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
135
"
Viewing
Trip
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
140
"
Swimming
Trip
Model.
lim"
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
145
3
Random
Utility
Model
Programs
and
Data
Sets
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
"
Fishing
Model
­
with
Out
of
state
WBType
Split.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
fish_
wb.
sd2
fish_
wb1.
sd2
fish_
wb2.
sd2
fish_
wb3.
sd2
fish_
wb4.
sd2
37762
37763
37764
37765
37766
Data
sets
containing
randomly
drawn
choice
sets
for
anglers.

"
Boating
Model
Glake
Split
3_
20_
02.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
boatg320.
sd2
boatg1.
sd2
boatg2.
sd2
boatg3.
sd2
boatg4.
sd2
37767
37768
37769
37770
37771
Datasets
containing
randomly
drawn
choice
sets
for
boaters.
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
4
"
Viewing
Model
3_
19_
02.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
viewg320.
sd2
view1.
sd2
view2.
sd2
view3.
sd2
view4.
sd2
37777
37778
37779
37780
37781
Data
sets
containing
randomly
drawn
choice
sets
for
viewers.

"
Swimming
Model
Glake
Split
3_
20_
02.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
swimg320.
sd2
swimg1.
sd2
swimg2.
sd2
swimg3.
sd2
swimg4.
sd2
37772
37773
37774
37775
37776
Data
sets
containing
randomly
drawn
choice
sets
for
swimmers.

"
Run
Random
Fish
Draws.
lim"
Data
utilized
Fishing
WBType
Split.
lpj
Limdep
project
containing
fish_
wb.
sd2
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
5
Fishing
WBType
Split
1.
lpj
Limdep
project
containing
fish_
wb1.
sd2
Fishing
WBType
Split
2.
lpj
Limdep
project
containing
fish_
wb2.
sd2
Fishing
WBType
Split
3.
lpj
Limdep
project
containing
fish_
wb3.
sd2
Fishing
WBType
Split
4.
lpj
Limdep
project
containing
fish_
wb4.
sd2
Data
created
None
Output
of
estimation
results
only.

"
Run
Random
Draws
for
Boating.
lim"
Data
utilized
Boating
Glake
Inland
Split.
lpj
Limdep
project
containing
boatg320.
sd2
Boating
Glake
Inland
Split
1.
lpj
Limdep
project
containing
boatg1.
sd2
Boating
Glake
Inland
Split
2.
lpj
Limdep
project
containing
boatg2.
sd2
Boating
Glake
Inland
Split
3.
lpj
Limdep
project
containing
boatg3.
sd2
Boating
Glake
Inland
Split
4.
lpj
Limdep
project
containing
boatg4.
sd2
Data
created
None
Output
of
estimation
results
only.

"
Run
Random
Draws
for
Viewing
Model.
lim"
Data
utilized
Flat
Viewing
Model.
lpj
Limdep
project
containing
viewg320.
sd2
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
6
Flat
Viewing
Model
1.
lpj
Limdep
project
containing
view1.
sd2
Flat
Viewing
Model
2.
lpj
Limdep
project
containing
view2.
sd2
Flat
Viewing
Model
3.
lpj
Limdep
project
containing
view3.
sd2
Flat
Viewing
Model
4.
lpj
Limdep
project
containing
view4.
sd2
Data
created
None
Output
of
estimation
results
only.

"
Run
Random
Draws
for
Swimming
Model.
lim"
Data
utilized
Swimming
Glake
Inland
Split.
lpj
Limdep
project
containing
swimg320.
sd2
Swimming
Glake
Inland
Split
1.
lpj
Limdep
project
containing
swimg1.
sd2
Swimming
Glake
Inland
Split
2.
lpj
Limdep
project
containing
swimg2.
sd2
Swimming
Glake
Inland
Split
3.
lpj
Limdep
project
containing
swimg3.
sd2
Swimming
Glake
Inland
Split
4.
lpj
Limdep
project
containing
swimg4.
sd2
Data
created
None
Output
of
estimation
results
only.

"
Random
Draw
Parameter
Analysis
for
Revised
Models.
xls"
Data
utilized
None
37782
Estimation
results
from
the
various
recreation
model
runs.
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
7
Data
created
None
"
Fishing
IV
Calculation.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
fsh_
trp.
sd2
Data
set
of
demographic
variables
and
calculated
inclusive
values
for
fishing
anglers.

"
Boating
IV
Calculation.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
boat_
trp.
sd2
Data
set
of
demographic
variables
and
calculated
inclusive
values
for
boaters.
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
8
"
Viewing
IV
Calculation.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
view_
trp.
sd2
Data
set
of
demographic
variables
and
calculated
inclusive
values
for
viewers.

"
Swimming
IV
Calculation.
sas"
Data
utilized
matrix4.
sd2
37759
Matrix
of
distances
from
zip
code
centroids
to
sites
in
Ohio.

rch_
info.
sd2
37757
Dataset
of
reach
attribute
variables
and
water
quality
variables.

fullset2.
sd2
37758
Dataset
of
participating
anglers
and
their
site
choice
information.

Data
created
swim_
trp.
sd2
Data
set
of
demographic
variables
and
calculated
inclusive
values
for
swimmers.

"
Fishing
Trip
Model.
lim"
Data
utilized
Fishing
Trip
Model.
lpj
Limdep
project
containing
fish_
trp.
sd2
Programs
Used
in
the
National
Benefits
Run
Program
Name
Dataset
DCN
Description
9
Data
created
None
Output
estimation
only.

"
Boating
Trip
Model.
lim"
Data
utilized
Boating
Trip
Model.
lpj
Limdep
project
containing
boat_
tp.
sd2
Data
created
None
Output
estimation
only.

"
Viewing
Trip
Model.
lim"
Data
utilized
Viewing
Trip
Model.
lpj
Limdep
project
containing
view_
trp.
sd2
Data
created
None
Output
estimation
only.

"
Swimming
Trip
Model.
lim"
Data
utilized
Swimming
Trip
Model.
lpj
Limdep
project
containing
swim_
trp.
sd2
Data
created
None
Output
estimation
only.
10
Estimation
of
the
Site
Choice
Models
of
Recreation
11
Generate
Participant
Data
Sets
with
Randomly
Drawn
Choice
Sets
12
"
Fishing
Model
­
with
Out
of
state
WBType
Split.
sas"
Randomly
draws
designated
fishing
sites
within
a
radius
from
the
participants
home.
The
choice
set
is
matched
with
demographic
data
from
the
respondent
and
a
data
set
is
created.
13
/*

PROGRAM:
Fishing
Model
­
with
Out
of
state
WBType
Split.
sas
AUTHORS:
Stuart
Smith
&
Mike
Needleman
&
George
Parsons
*/
/*****************************************************************************/
/*
CITATION
OF
ORIGINAL
PROGRAM
CODE
*/
/*****************************************************************************/
/*
*/
/*
The
original
form
of
this
random
draw
program
was
*/
/*
created
by
Mike
Needleman
and
George
Parsons
at
the
University
of
*/
/*
Delaware
under
a
U.
S.
EPA
cooperative
agreement
for
Measuring
the
*/
/*
Benefits
of
Water
Quality
Improvements.
*/
/*****************************************************************************/

/*****************************************************************************/
/*
MODIFICATIONS
TO
THE
ORIGINAL
CODE
*/
/*****************************************************************************/
/*
*/
/*
Few
variable
names
remain
unchanged.
The
majority
of
variable
names
*/
/*
have
been
changed
to
reflect
the
current
application.
An
additional
*/
/*
routine
RESETIT
was
created
by
Stuart
Smith.
In
addition,
changes
to
*/
/*
the
drawing
criteria
as
well
as
links
to
the
water
quality
data
for
*/
/*
purposes
of
the
random
draw
have
been
added
or
modified
from
the
*/
/*
original
program
code.
All
modifications
have
been
made
by
Stuart
*/
/*
Smith,
an
employee
of
Abt
Associates.
*/
/*****************************************************************************/

/*
REVISION
DATE:
4/
12/
2002
ANGLERS
Sites
are
drawn
on
the
following
criteria:

1)
the
site
is
within
the
distance
traveled
to
the
chosen
site
or
120
miles,
whichever
is
greater.
2)
the
site
is
not
the
chosen
site
*/

libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
draw=
60;
%
let
activity=
fisher;
%
let
distmax=
120;
%
let
finalSet=
fish_
wb;

/*
Setup
ouput
dataset
*/
14
data
randrch
(
keep
=
full_
id
siteid
rch1­
rch&
draw
dst1­
dst&
draw);

/*
Initialize
arrays
for
draw
construction
*/
/*
Chosen
site,
59
random
draws
*/
array
rch{*}
rch1­
rch&
draw;
array
dst{*}
dst1­
dst&
draw;
array
norepl{*}
norepl1­
norepl&
draw;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
set
demogr.
fullset2;

/*
Drop
non
fishermen,
we
don't
need
them
here.
*/

if
&
activity
=
0
then
delete;

/*
Drop
non­
matched
*/

if
siteid
=
0
then
put
'
NOT
MATCHED
TO
A
SITE!!!
Respnum
=
'
respnum;
if
siteid
=
0
then
delete;

visitid=
siteid;

/*
Convert
zipcode
to
row
number
in
the
distance
matrix.
The
matrix
contains
one
row
for
each
respondent
zipcode.
The
zip_
fmt
translates
the
zipcode
into
its
corresponding
row
number
in
the
distance
matrix
(
1­
337)
*/

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
rchdist{
1954}
_
1­_
1954;
array
c{
4}
c1­
c4;
array
count{
1954}
cnt1­
cnt1954;

set
lori.
matrix4
point=
zipid;

do
l
=
1
to
&
draw;
norepl{
l}=
0;
end;

c1=
0;
lori=
0;

/*
Obtain
the
chosen
reach
id
number
*/
if
visitid
^=
999
then
do;
/*
Chose
site
within
Ohio
*/
rchid=
visitid;
newrchid=
rchid;
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!';
set
reach.
rch_
info
point=
dsta;
if
glake
=
1
then
do;
/*
is
chosen
site
a
great
lake
site?
*/
k=
1;
15
strt1=
2;
end1=
20;
strt2=
21;
end2=
40;
strt3=
41;
end3=
60;
end;
if
river
=
1
then
do;
/*
river
for
chosen
site
*/
k=
21;
strt1=
1;
end1=
20;
strt2=
22;
end2=
40;
strt3=
41;
end3=
60;
end;
if
glake=
0
and
river
=
0
then
do;
/*
lake
for
chosen
site
*/
k=
41;
strt1=
1;
end1=
20;
strt2=
21;
end2=
40;
strt3=
42;
end3=
60;
end;
link
chosen;
chdist=
dst(
k);
end;
/*
chosen
site
is
within
Ohio
*/
else
do;
/*
chosen
site
outside
of
Ohio
*/
set
reach.
outstate
point=
outlink;
if
glake
=
1
then
do;
/*
is
chosen
site
a
great
lake
site?
*/
k=
1;
strt1=
2;
end1=
20;
strt2=
21;
end2=
40;
strt3=
41;
end3=
60;
end;
if
glake
=
0
then
do;
/*
not
a
great
lake
for
chosen
site
*/
k=
21;
strt1=
1;
end1=
20;
strt2=
22;
end2=
40;
strt3=
41;
end3=
60;
end;
if
glake=
0
and
river
=
0
then
do;
/*
lake
for
chosen
site
*/
k=
41;
strt1=
1;
end1=
20;
16
strt2=
21;
end2=
40;
strt3=
42;
end3=
60;
end;
dst(
k)=
tripdist;
/*
set
distance
to
calculated
distance
from
site
matching
*/
rch(
k)=
999;
/*
set
reach
to
999
so
we
don't
match
it
and
can
set
it
to
be
chosen
*/
chdist=
dst(
k);
end;

if
visitid
=
0
then
delete;

/*************************************/
/*
MACRO
­
to
build
selected
sets
*/
/*************************************/

%
macro
buildset(
strt=,
ennd=,
cnt=,
maxd=,
boating=,
crit=);

do
k
=
&
strt
to
&
ennd;
if
k
=
&
strt
then
do;
do
until
(
lori=
1954);
lori=
lori+
1;
link
reachit;
set
reach.
rch_
info
point=
lori;
/*
point
to
reach
row
in
water
data
*/
/*
trip=
max(
chdist,&
maxd);*/
trip
=
&
maxd;
if
&
boating=
1
then
do;
if
ramp=
1
or
boatrent=
1
or
dock=
1
or
sailbt=
1
then
boatable=
1;
else
boatable=
0;
end;
if
&
crit
then
do;
c(
1)
=
c(
1)
+
1;
count(
c(
1))
=
lori;
end;
/*
if
criteria
*/
end;
/*
do
until
*/
end;
/*
if
k=&
strt
*/
start=
1;
range=
1;
if
c(
1)
<
&
cnt­
1
then
do;
if
k
<=
(
c(
1)+
1)
then
do;
lori=
count(
k­
1);
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
/*
else
do
*/
end;
else
link
rndset;
end;
/*
do
k=&
strt
to
&
ennd
*/
link
resetit;
17
%
mend
buildset;

/*************************************/
/*
END
MACRO
­
to
build
selected
sets*/
/*************************************/

/*
Call
macro
for
each
nest
to
build
the
sets
*/

%
buildset(
strt=
strt1,
ennd=
end1,
cnt=
end1,
maxd=
250,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
glake=
1));
%
buildset(
strt=
strt2,
ennd=
end2,
cnt=
end1,
maxd=&
distmax,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
river=
1));
%
buildset(
strt=
strt3,
ennd=
end3,
cnt=
end1,
maxd=&
distmax,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
river=
0)
&
(
glake=
0));

do
i
=
1
to
&
draw;
if
rch&
draw
=
.
then
delete;
end;

output;
link
resetit;
goto
end;

/********************************************************************/
/*
CODE
ROUTINES
FOR
BULDING
THE
CHOICE
SET
*/
/********************************************************************/

/*
Takes
the
lori
index
number
(
1­
1954)
and
translates
it
into
a
reachid
number
*/
reachit:
rchid
=
put(
lori,
lori_
fmt.);
if
rchid
=
9999
then
put
'
REACH
ID
MISMATCH!!!';

/*
Translates
the
reachid
number
into
its
sequence
number
which
corresponds
to
the
variable
in
the
distance
matrix
containing
the
distance
from
the
zipcode
to
that
reach.
*/
chosen:
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!';
dst(
k)
=
rchdist(
dsta);
rch(
k)
=
rchid;
return;

/*
Take
the
full
set
of
possible
reaches
and
randomly
select
a
subset
of
those
possible
sites.
Size
of
random
draw
is
controled
by
the
size
of
the
initial
rch
array.
*/
rndset:
if
c(
range)
>
0
then
do;
relori:
lori
=
int(
ranuni(
0)
*
c(
range));
if
lori
=
0
then
lori
=
c(
range);
lori
=
count(
lori);
18
do
i
=
start
to
k­
1;
if
norepl(
i)
=
lori
then
goto
relori;
end;
norepl(
k)
=
lori;
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
return;

/*
Reset
the
necessary
variables
to
zero
for
the
next
respondent.
*/
resetit:
do
i
=
1
to
&
draw;
norepl{
i}=
0;
end;
do
i
=
1
to
1954;
count{
i}=
0;
end;
c1=
0;
lori=
0;
cold=
0;
coldrch=
0;
chdist=
0;
miss=
0;
return;

end:
run;

/*
End
of
Random
Draw
program
code
*/

proc
print
data=
randrch;
format
rch1­
rch&
draw
13.2
siteid
13.2;
quit;

/*
The
following
section
adds
the
remaining
demographic
data
and
water
quality
data.
It
also
twists
the
data
into
a
limdep
fashion
dataset.
*/

/*****************************************************************************
*
GET
DEMOGRAHIC
DATA
*
*****************************************************************************/

data
evryone;
set
demogr.
fullset2;
if
&
activity=
1;

/****************************************************************************
*
GET
INFORMATION
FROM
RANDOM
DATA
SETS
*
****************************************************************************/

data
random;
19
set
randrch;

/****************************************************************************
*
MERGE
DEMOGRAPHICS
AND
RANDOM
*
****************************************************************************/

proc
sort
data=
random;
by
full_
id
siteid;

proc
sort
data=
evryone;
by
full_
id
siteid;

data
combine;
merge
evryone
random;
by
full_
id
siteid;

/****************************************************************************
*
PREPARE
FILE
FOR
LIMDEP
*
*****************************************************************************/

data
concat;
set
combine;
array
reach{&
draw}
rch1­
rch&
draw;
array
dist{&
draw}
dst1­
dst&
draw;
do
I=
1
to
&
draw;
lk=
reach{
I};
ds=
dist{
I};
if
ds=
0
and
lk
^=
999
then
ds=.
5;
/*
Keep
0
distance
for
outside
Ohio
sites
*/
output;
end;

/*****************************************************************************
*
CALCULATE
VISITDM
VARIABLE
*
******************************************************************************/

data
here;
set
concat;
drop
rch1­
rch&
draw
dst1­
dst&
draw;

/*
Delete
records
within
a
individual's
opportunity
set
for
which
there
were
no
lakes
available.
*/

if
lk='.'
then
delete;

/*
This
visitdm
variable
is
only
for
the
lakes,
it
does
not
work
for
the
no
trip
lines
*/

if
lk=
siteid
then
visitdm=
1;
else
visitdm=
0;
obnum=_
n_;
20
/*****************************************************************************
*
OUTPUT
DATA
SET
*
******************************************************************************/

data
twst;
set
here;
if
full_
id
=
.
then
delete;

proc
sort
data=
twst;
by
full_
id
lk;
quit;

/*
Read
in
the
raw
data
*/

data
initial;
set
twst(
rename=(
lk=
rf1id));

/*
Calc
for
real
sites
*/

if
rf1id
=
999
then
skipit
=
1;
else
skipit
=
0;

if
skipit=
0
then
do;
ind=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
ind=
9999
then
put
'
REACH
MISMATCH!!!!';

set
reach.
rch_
info
point=
ind;
/*
site
attribute
data
*/

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Create
Cost
of
trip
variables
*/

op_
cost=(
wage*(
ds/
40))*
2;
tr_
cost=(((
ds*
0.29*
paid_
cst*
car)/
share))*
2;

price1=
0.5*
op_
cost
+
tr_
cost;
price2=
0.33*
op_
cost
+
tr_
cost;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

tot_
n
=
nit
+
tkn;
nij=
40;
asc
=
0;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/
21
if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

end;
/*
Skipit
=
0
*/

/*
Set
variables
for
sites
outside
Ohio
*/
if
skipit
=
1
then
do;
set
reach.
outstate
point=
outlink;
if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
segl
^=
0
then
rchsze=
log(
segl);
22
else
rchsze
=
0;
end;
else
do;
/*
small
lakes
*/
if
ln_
acre=.
then
ln_
acre=
0;
pi
=
3.141592654;
area
=
segl**
2;
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
river=
1
then
do;
fish300m
=
461.366;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
6.519;
end;
if
glake=
1
then
do;
fish300m
=
198.313;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
5.021;
end;
if
river=
0
and
glake=
0
then
do;
fish300m
=
462.438;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
9.173;
end;

ramp=
0;
ln_
acre=
0;
ln_
lndac=
0;
fish=
0;
beach=
0;
dock=
0;
boatrent=
0;
awqc_
ex=
0;
park=
0;
amm=
0;
bod=
0;
iwb2=
0;
nit=
0;
oil=
0;
phos=
0;
tss=
0;
tot_
n=
0;
iwb2=
0;
fuel=
0;
motor=
0;
sailing=
0;
own_
boat=
0;
boat_
use=
0;
picnic=
0;
nij=
40;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
full_
id
respnum
rf1id
price1
price2
ramp
ln_
acre
ln_
lndac
asc
own_
boat
boat_
use
fish
beach
dock
picnic
glake
fuel
motor
sailing
nij
visitdm
visits
obnum
kids6
new_
tox
awqc_
ex
park
rch_
len
rch_
wid
river
trpcost
timcost
age
income
ln_
inc
23
amm
bod
nit
oil
phos
tkn
tss
tot_
n
iwb2
rchsze
fisher
swimer
boater
viewer
college
house_
sz
boat_
use
rnt_
boat
tow_
boat
mor_
boat
fish300m
fish100m
fish1m
wgt_
300m
ds
wage
unempl
home_
mk
retired
paid_
cst
car
share;
run;

/***********************************************/
/*
CREATE
OUTPUT
DATASET
WITH
SELECT
VARIABLES
*/
/***********************************************/

proc
sort
data=
initial;
by
full_
id
obnum;
quit;

data
rand.&
finalSet;
set
initial;
run;
24
"
Boating
Model
Glake
Split
3_
20_
02.
sas"
Randomly
draws
designated
boating
sites
within
a
radius
from
the
participants
home.
The
choice
set
is
matched
with
demographic
data
from
the
respondent
and
a
data
set
is
created.
25
/*

PROGRAM:
Boating
Model
Glake
Split
3_
20_
02.
sas
AUTHORS:
Stuart
Smith
&
Mike
Needleman
&
George
Parsons
*/
/*****************************************************************************/
/*
CITATION
OF
ORIGINAL
PROGRAM
CODE
*/
/*****************************************************************************/
/*
*/
/*
The
original
form
of
this
random
draw
program
was
*/
/*
created
by
Mike
Needleman
and
George
Parsons
at
the
University
of
*/
/*
Delaware
under
a
U.
S.
EPA
cooperative
agreement
for
Measuring
the
*/
/*
Benefits
of
Water
Quality
Improvements.
*/
/*****************************************************************************/

/*****************************************************************************/
/*
MODIFICATIONS
TO
THE
ORIGINAL
CODE
*/
/*****************************************************************************/
/*
*/
/*
Few
variable
names
remain
unchanged.
The
majority
of
variable
names
*/
/*
have
been
changed
to
reflect
the
current
application.
An
additional
*/
/*
routine
RESETIT
was
created
by
Stuart
Smith.
In
addition,
changes
to
*/
/*
the
drawing
criteria
as
well
as
links
to
the
water
quality
data
for
*/
/*
purposes
of
the
random
draw
have
been
added
or
modified
from
the
*/
/*
original
program
code.
All
modifications
have
been
made
by
Stuart
*/
/*
Smith,
an
employee
of
Abt
Associates.
*/
/*****************************************************************************/

/*
REVISION
DATE:
3/
20/
2002
BOATERS
Sites
are
drawn
on
the
following
criteria:

1)
the
site
is
within
the
distance
traveled
to
the
chosen
site
or
120
miles,
whichever
is
greater.
2)
the
site
is
not
the
chosen
site
3)
the
site
is
boatable
*/

libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
draw=
40;
%
let
activity=
boater;
%
let
distmax=
120;
%
let
finalSet=
boatg320;
26
/*
Setup
ouput
dataset
*/
data
randrch
(
keep
=
full_
id
siteid
rch1­
rch&
draw
dst1­
dst&
draw);

/*
Initialize
arrays
for
draw
construction
*/
/*
Chosen
site,
39
random
draws
*/
array
rch{*}
rch1­
rch&
draw;
array
dst{*}
dst1­
dst&
draw;
array
norepl{*}
norepl1­
norepl&
draw;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
set
demogr.
fullset2;

/*
Drop
non
fishermen,
we
don't
need
them
here.
*/

if
&
activity
=
0
then
delete;

/*
Drop
non­
matched
*/

if
siteid
=
0
then
put
'
NOT
MATCHED
TO
A
SITE!!!
Respnum
=
'
respnum;
if
siteid
=
0
then
delete;

visitid=
siteid;

/*
Convert
zipcode
to
row
number
in
the
distance
matrix.
The
matrix
contains
one
row
for
each
respondent
zipcode.
The
zip_
fmt
translates
the
zipcode
into
its
corresponding
row
number
in
the
distance
matrix
(
1­
337)
*/

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
rchdist{
1954}
_
1­_
1954;
array
c{
4}
c1­
c4;
array
count{
1954}
cnt1­
cnt1954;

set
lori.
matrix4
point=
zipid;

do
l
=
1
to
&
draw;
norepl{
l}=
0;
end;

c1=
0;
lori=
0;

/*
Obtain
the
chosen
reach
id
number
*/
if
visitid
^=
999
then
do;
/*
Chose
site
within
Ohio
*/
rchid=
visitid;
newrchid=
rchid;
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!
Respnum
'
respnum
'
SITE:
'
rchid;
if
dsta
=
9999
then
delete;
set
reach.
rch_
info
point=
dsta;
27
if
glake
=
1
then
do;
/*
is
chosen
site
a
great
lake
site?
*/
k=
1;
strt1=
2;
end1=
20;
strt2=
21;
end2=
40;
end;
if
glake
=
0
then
do;
/*
not
a
great
lake
for
chosen
site
*/
k=
21;
strt1=
1;
end1=
20;
strt2=
22;
end2=
40;
end;
link
chosen;
chdist=
dst(
k);
end;
/*
chosen
site
is
within
Ohio
*/
else
delete;

if
visitid
=
0
then
delete;

/*************************************/
/*
MACRO
­
to
build
selected
sets
*/
/*************************************/

%
macro
buildset(
strt=,
ennd=,
cnt=,
maxd=,
boating=,
crit=);

do
k
=
&
strt
to
&
ennd;
if
k
=
&
strt
then
do;
do
until
(
lori=
1954);
lori=
lori+
1;
link
reachit;
set
reach.
rch_
info
point=
lori;
/*
point
to
reach
row
in
water
data
*/
trip=
max(
chdist,&
maxd);
if
&
boating=
1
then
do;
if
ramp=
1
or
boatrent=
1
or
dock=
1
or
sailbt=
1
then
boatable=
1;
else
boatable=
0;
end;
if
&
crit
then
do;
c(
1)
=
c(
1)
+
1;
count(
c(
1))
=
lori;
end;
/*
if
criteria
*/
end;
/*
do
until
*/
end;
/*
if
k=&
strt
*/
start=
1;
range=
1;
if
c(
1)
<
&
cnt­
1
then
do;
if
k
<=
(
c(
1)+
1)
then
do;
lori=
count(
k­
1);
link
reachit;
end;
28
else
do;
dst(
k)=.;
rch(
k)=.;
end;
/*
else
do
*/
end;
else
link
rndset;
end;
/*
do
k=&
strt
to
&
ennd
*/
link
resetit;

%
mend
buildset;

/*************************************/
/*
END
MACRO
­
to
build
selected
sets*/
/*************************************/

/*
Call
macro
for
each
nest
to
build
the
sets
*/

%
buildset(
strt=
strt1,
ennd=
end1,
cnt=
end1,
maxd=
300,
boating=
1,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
glake=
1)
&
(
boatable=
1));
%
buildset(
strt=
strt2,
ennd=
end2,
cnt=
end1,
maxd=&
distmax,
boating=
1,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
glake=
0)
&
(
boatable=
1));

output;
link
resetit;
goto
end;

/********************************************************************/
/*
CODE
ROUTINES
FOR
BULDING
THE
CHOICE
SET
*/
/********************************************************************/

/*
Takes
the
lori
index
number
(
1­
1954)
and
translates
it
into
a
reachid
number
*/
reachit:
rchid
=
put(
lori,
lori_
fmt.);
if
rchid
=
9999
then
put
'
REACH
ID
MISMATCH!!!';

/*
Translates
the
reachid
number
into
its
sequence
number
which
corresponds
to
the
variable
in
the
distance
matrix
containing
the
distance
from
the
zipcode
to
that
reach.
*/
chosen:
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!';
dst(
k)
=
rchdist(
dsta);
rch(
k)
=
rchid;
return;

/*
Take
the
full
set
of
possible
reaches
and
randomly
select
a
subset
of
those
possible
sites.
Size
of
random
draw
is
controled
by
the
size
of
the
initial
rch
array.
*/
rndset:
if
c(
range)
>
0
then
do;
relori:
29
lori
=
int(
ranuni(
0)
*
c(
range));
if
lori
=
0
then
lori
=
c(
range);
lori
=
count(
lori);
do
i
=
start
to
k­
1;
if
norepl(
i)
=
lori
then
goto
relori;
end;
norepl(
k)
=
lori;
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
return;

/*
Reset
the
necessary
variables
to
zero
for
the
next
respondent.
*/
resetit:
do
i
=
1
to
&
draw;
norepl{
i}=
0;
end;
do
i
=
1
to
1954;
count{
i}=
0;
end;
c1=
0;
lori=
0;
cold=
0;
coldrch=
0;
chdist=
0;
miss=
0;
return;

end:
run;

/*
End
of
Random
Draw
program
code
*/

proc
print
data=
randrch;
format
rch1­
rch&
draw
13.2
siteid
13.2;
quit;

/*
The
following
section
adds
the
remaining
demographic
data
and
water
quality
data.
It
also
twists
the
data
into
a
limdep
fashion
dataset.
*/

/*****************************************************************************
*
GET
DEMOGRAHIC
DATA
*
*****************************************************************************/

data
evryone;
set
demogr.
fullset2;
if
&
activity=
1;

/****************************************************************************
*
GET
INFORMATION
FROM
RANDOM
DATA
SETS
*
30
****************************************************************************/

data
random;
set
randrch;

/****************************************************************************
*
MERGE
DEMOGRAPHICS
AND
RANDOM
*
****************************************************************************/

proc
sort
data=
random;
by
full_
id
siteid;

proc
sort
data=
evryone;
by
full_
id
siteid;

data
combine;
merge
evryone
random;
by
full_
id
siteid;

/****************************************************************************
*
PREPARE
FILE
FOR
LIMDEP
*
*****************************************************************************/

data
concat;
set
combine;
array
reach{&
draw}
rch1­
rch&
draw;
array
dist{&
draw}
dst1­
dst&
draw;
do
I=
1
to
&
draw;
lk=
reach{
I};
ds=
dist{
I};
if
ds=
0
and
lk
^=
999
then
ds=.
5;
/*
Keep
0
distance
for
outside
Ohio
sites
*/
output;
end;

/*****************************************************************************
*
CALCULATE
VISITDM
VARIABLE
*
******************************************************************************/

data
here;
set
concat;
drop
rch1­
rch&
draw
dst1­
dst&
draw;

/*
Delete
records
within
a
individual's
opportunity
set
for
which
there
were
no
lakes
available.
*/

if
lk='.'
then
delete;

/*
This
visitdm
variable
is
only
for
the
lakes,
it
does
not
work
for
the
no
trip
lines
*/

if
lk=
siteid
then
visitdm=
1;
31
else
visitdm=
0;
obnum=_
n_;

/*****************************************************************************
*
OUTPUT
DATA
SET
*
******************************************************************************/

data
twst;
set
here;
if
full_
id
=
.
then
delete;

proc
sort
data=
twst;
by
full_
id
lk;
quit;

/*
Read
in
the
raw
data
*/

data
initial;
set
twst(
rename=(
lk=
rf1id));

/*
Calc
for
real
sites
*/

if
rf1id
=
999
then
skipit
=
1;
else
skipit
=
0;

if
skipit=
0
then
do;
ind=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
ind=
9999
then
put
'
REACH
MISMATCH!!!!';

set
reach.
rch_
info
point=
ind;
/*
site
attribute
data
*/

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Create
Cost
of
trip
variables
*/

op_
cost=(
wage*(
ds/
40))*
2;
tr_
cost=(((
ds*
0.29*
paid_
cst*
car)/
share))*
2;

price1=
0.5*
op_
cost
+
tr_
cost;
price2=
0.33*
op_
cost
+
tr_
cost;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

tot_
n
=
nit
+
tkn;
nij=
40;
asc
=
0;
32
/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

end;
/*
Skipit
=
0
*/

/*
Set
variables
for
sites
outside
Ohio
*/
if
skipit
=
1
then
do;
set
reach.
outstate
point=
outlink;
if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/
33
if
river=
1
or
glake=
1
then
do;
if
segl
^=
0
then
rchsze=
log(
segl);
else
rchsze
=
0;
end;
else
do;
/*
small
lakes
*/
if
ln_
acre=.
then
ln_
acre=
0;
pi
=
3.141592654;
area
=
segl**
2;
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
river=
1
then
do;
fish300m
=
461.366;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
6.519;
end;
if
glake=
1
then
do;
fish300m
=
198.313;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
5.021;
end;
if
river=
0
and
glake=
0
then
do;
fish300m
=
462.438;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
9.173;
end;

ramp=
0;
ln_
acre=
0;
ln_
lndac=
0;
fish=
0;
beach=
0;
dock=
0;
boatrent=
0;
awqc_
ex=
0;
park=
0;
amm=
0;
bod=
0;
iwb2=
0;
nit=
0;
oil=
0;
phos=
0;
tss=
0;
tot_
n=
0;
iwb2=
0;
fuel=
0;
motor=
0;
sailing=
0;
own_
boat=
0;
boat_
use=
0;
picnic=
0;
nij=
40;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
full_
id
respnum
rf1id
price1
price2
ramp
ln_
acre
ln_
lndac
asc
own_
boat
boat_
use
34
fish
beach
dock
picnic
glake
fuel
motor
sailing
nij
visitdm
visits
obnum
kids6
new_
tox
awqc_
ex
park
rch_
len
rch_
wid
river
trpcost
timcost
age
income
ln_
inc
amm
bod
nit
oil
phos
tkn
tss
tot_
n
iwb2
rchsze
fisher
swimer
boater
viewer
college
house_
sz
boat_
use
rnt_
boat
tow_
boat
mor_
boat
fish300m
fish100m
fish1m
wgt_
300m
ds
wage
unempl
home_
mk
retired
paid_
cst
car
share;
run;

/***********************************************/
/*
CREATE
OUTPUT
DATASET
WITH
SELECT
VARIABLES
*/
/***********************************************/

proc
sort
data=
initial;
by
full_
id
obnum;
quit;

data
rand.&
finalSet;
set
initial;
run;
35
"
Viewing
Model
3_
19_
02.
sas"
Randomly
draws
viewing
sites
within
a
radius
from
the
participants
home.
The
choice
set
is
matched
with
demographic
data
from
the
respondent
and
a
data
set
is
created.
36
/*

PROGRAM:
Viewing
Model
3_
19_
02.
sas
AUTHORS:
Stuart
Smith
&
Mike
Needleman
&
George
Parsons
*/
/*****************************************************************************/
/*
CITATION
OF
ORIGINAL
PROGRAM
CODE
*/
/*****************************************************************************/
/*
*/
/*
The
original
form
of
this
random
draw
program
was
*/
/*
created
by
Mike
Needleman
and
George
Parsons
at
the
University
of
*/
/*
Delaware
under
a
U.
S.
EPA
cooperative
agreement
for
Measuring
the
*/
/*
Benefits
of
Water
Quality
Improvements.
*/
/*****************************************************************************/

/*****************************************************************************/
/*
MODIFICATIONS
TO
THE
ORIGINAL
CODE
*/
/*****************************************************************************/
/*
*/
/*
Few
variable
names
remain
unchanged.
The
majority
of
variable
names
*/
/*
have
been
changed
to
reflect
the
current
application.
An
additional
*/
/*
routine
RESETIT
was
created
by
Stuart
Smith.
In
addition,
changes
to
*/
/*
the
drawing
criteria
as
well
as
links
to
the
water
quality
data
for
*/
/*
purposes
of
the
random
draw
have
been
added
or
modified
from
the
*/
/*
original
program
code.
All
modifications
have
been
made
by
Stuart
*/
/*
Smith,
an
employee
of
Abt
Associates.
*/
/*****************************************************************************/

/*
REVISION
DATE:
3/
19/
2002
ANGLERS
Sites
are
drawn
on
the
following
criteria:

1)
the
site
is
within
the
distance
traveled
to
the
chosen
site
or
120
miles,
whichever
is
greater.
2)
the
site
is
not
the
chosen
site
*/

libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
draw=
40;
%
let
activity=
viewer;
%
let
distmax=
120;
%
let
finalSet=
view319;

/*
Setup
ouput
dataset
*/
37
data
randrch
(
keep
=
full_
id
siteid
rch1­
rch&
draw
dst1­
dst&
draw);

/*
Initialize
arrays
for
draw
construction
*/
/*
Chosen
site,
39
random
draws
*/
array
rch{*}
rch1­
rch&
draw;
array
dst{*}
dst1­
dst&
draw;
array
norepl{*}
norepl1­
norepl&
draw;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
set
demogr.
fullset2;

/*
Drop
non
viewers,
we
don't
need
them
here.
*/

if
&
activity
=
0
then
delete;

/*
Drop
non­
matched
*/

if
siteid
=
0
then
put
'
NOT
MATCHED
TO
A
SITE!!!
Respnum
=
'
respnum;
if
siteid
=
0
then
delete;

visitid=
siteid;

/*
Convert
zipcode
to
row
number
in
the
distance
matrix.
The
matrix
contains
one
row
for
each
respondent
zipcode.
The
zip_
fmt
translates
the
zipcode
into
its
corresponding
row
number
in
the
distance
matrix
(
1­
337)
*/

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
rchdist{
1954}
_
1­_
1954;
array
c{
4}
c1­
c4;
array
count{
1954}
cnt1­
cnt1954;

set
lori.
matrix4
point=
zipid;

do
l
=
1
to
&
draw;
norepl{
l}=
0;
end;

c1=
0;
lori=
0;

/*
Obtain
the
chosen
reach
id
number
*/
if
visitid
^=
999
then
do;
/*
Chose
site
within
Ohio
*/
rchid=
visitid;
newrchid=
rchid;
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!
Respnum
'
respnum
'
SITE:
'
rchid;
if
dsta
=
9999
then
delete;
set
reach.
rch_
info
point=
dsta;
k=
1;
38
link
chosen;
chdist=
dst(
k);
end;
/*
chosen
site
is
within
Ohio
*/
else
delete;

if
visitid
=
0
then
delete;

/*************************************/
/*
MACRO
­
to
build
selected
sets
*/
/*************************************/

%
macro
buildset(
strt=,
ennd=,
cnt=,
maxd=,
boating=,
crit=);

do
k
=
&
strt
to
&
ennd;
if
k
=
&
strt
then
do;
do
until
(
lori=
1954);
lori=
lori+
1;
link
reachit;
set
reach.
rch_
info
point=
lori;
/*
point
to
reach
row
in
water
data
*/
trip=
max(
chdist,&
maxd);
if
&
boating=
1
then
do;
if
ramp=
1
or
boatrent=
1
or
dock=
1
or
sailbt=
1
then
boatable=
1;
else
boatable=
0;
end;
if
&
crit
then
do;
c(
1)
=
c(
1)
+
1;
count(
c(
1))
=
lori;
end;
/*
if
criteria
*/
end;
/*
do
until
*/
end;
/*
if
k=&
strt
*/
start=
1;
range=
1;
if
c(
1)
<
&
cnt­
1
then
do;
if
k
<=
(
c(
1)+
1)
then
do;
lori=
count(
k­
1);
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
/*
else
do
*/
end;
else
link
rndset;
end;
/*
do
k=&
strt
to
&
ennd
*/
link
resetit;

%
mend
buildset;

/*************************************/
/*
END
MACRO
­
to
build
selected
sets*/
/*************************************/
39
/*
Call
macro
for
each
nest
to
build
the
sets
*/

%
buildset(
strt=
2,
ennd=&
draw,
cnt=&
draw,
maxd=&
distmax,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip));

output;
link
resetit;
goto
end;

/********************************************************************/
/*
CODE
ROUTINES
FOR
BULDING
THE
CHOICE
SET
*/
/********************************************************************/

/*
Takes
the
lori
index
number
(
1­
1954)
and
translates
it
into
a
reachid
number
*/
reachit:
rchid
=
put(
lori,
lori_
fmt.);
if
rchid
=
9999
then
put
'
REACH
ID
MISMATCH!!!';

/*
Translates
the
reachid
number
into
its
sequence
number
which
corresponds
to
the
variable
in
the
distance
matrix
containing
the
distance
from
the
zipcode
to
that
reach.
*/
chosen:
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!';
dst(
k)
=
rchdist(
dsta);
rch(
k)
=
rchid;
return;

/*
Take
the
full
set
of
possible
reaches
and
randomly
select
a
subset
of
those
possible
sites.
Size
of
random
draw
is
controled
by
the
size
of
the
initial
rch
array.
*/
rndset:
if
c(
range)
>
0
then
do;
relori:
lori
=
int(
ranuni(
0)
*
c(
range));
if
lori
=
0
then
lori
=
c(
range);
lori
=
count(
lori);
do
i
=
start
to
k­
1;
if
norepl(
i)
=
lori
then
goto
relori;
end;
norepl(
k)
=
lori;
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
return;

/*
Reset
the
necessary
variables
to
zero
for
the
next
respondent.
*/
resetit:
40
do
i
=
1
to
&
draw;
norepl{
i}=
0;
end;
do
i
=
1
to
1954;
count{
i}=
0;
end;
c1=
0;
lori=
0;
cold=
0;
coldrch=
0;
chdist=
0;
miss=
0;
return;

end:
run;

/*
End
of
Random
Draw
program
code
*/

proc
print
data=
randrch;
format
rch1­
rch&
draw
13.2
siteid
13.2;
quit;

/*
The
following
section
adds
the
remaining
demographic
data
and
water
quality
data.
It
also
twists
the
data
into
a
limdep
fashion
dataset.
*/

/*****************************************************************************
*
GET
DEMOGRAHIC
DATA
*
*****************************************************************************/

data
evryone;
set
demogr.
fullset2;
if
&
activity=
1;

/****************************************************************************
*
GET
INFORMATION
FROM
RANDOM
DATA
SETS
*
****************************************************************************/

data
random;
set
randrch;

/****************************************************************************
*
MERGE
DEMOGRAPHICS
AND
RANDOM
*
****************************************************************************/

proc
sort
data=
random;
by
full_
id
siteid;

proc
sort
data=
evryone;
by
full_
id
siteid;

data
combine;
merge
evryone
random;
41
by
full_
id
siteid;

/****************************************************************************
*
PREPARE
FILE
FOR
LIMDEP
*
*****************************************************************************/

data
concat;
set
combine;
array
reach{&
draw}
rch1­
rch&
draw;
array
dist{&
draw}
dst1­
dst&
draw;
do
I=
1
to
&
draw;
lk=
reach{
I};
ds=
dist{
I};
if
ds=
0
and
lk
^=
999
then
ds=.
5;
/*
Keep
0
distance
for
outside
Ohio
sites
*/
output;
end;

/*****************************************************************************
*
CALCULATE
VISITDM
VARIABLE
*
******************************************************************************/

data
here;
set
concat;
drop
rch1­
rch&
draw
dst1­
dst&
draw;

/*
Delete
records
within
a
individual's
opportunity
set
for
which
there
were
no
lakes
available.
*/

if
lk='.'
then
delete;

/*
This
visitdm
variable
is
only
for
the
lakes,
it
does
not
work
for
the
no
trip
lines
*/

if
lk=
siteid
then
visitdm=
1;
else
visitdm=
0;
obnum=_
n_;

/*****************************************************************************
*
OUTPUT
DATA
SET
*
******************************************************************************/

data
twst;
set
here;
if
full_
id
=
.
then
delete;

proc
sort
data=
twst;
by
full_
id
lk;
quit;

/*
Read
in
the
raw
data
*/
42
data
initial;
set
twst(
rename=(
lk=
rf1id));

/*
Calc
for
real
sites
*/

if
rf1id
=
999
then
skipit
=
1;
else
skipit
=
0;

if
skipit=
0
then
do;
ind=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
ind=
9999
then
put
'
REACH
MISMATCH!!!!';

set
reach.
rch_
info
point=
ind;
/*
site
attribute
data
*/

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Create
Cost
of
trip
variables
*/

op_
cost=(
wage*(
ds/
40))*
2;
tr_
cost=(((
ds*
0.29*
paid_
cst*
car)/
share))*
2;

price1=
0.5*
op_
cost
+
tr_
cost;
price2=
0.33*
op_
cost
+
tr_
cost;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

tot_
n
=
nit
+
tkn;
nij=
40;
asc
=
0;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
43
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

end;
/*
Skipit
=
0
*/

/*
Set
variables
for
sites
outside
Ohio
*/
if
skipit
=
1
then
do;
set
reach.
outstate
point=
outlink;
if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
segl
^=
0
then
rchsze=
log(
segl);
else
rchsze
=
0;
end;
else
do;
/*
small
lakes
*/
if
ln_
acre=.
then
ln_
acre=
0;
pi
=
3.141592654;
area
=
segl**
2;
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/
44
if
river=
1
then
do;
fish300m
=
461.366;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
6.519;
end;
if
glake=
1
then
do;
fish300m
=
198.313;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
5.021;
end;
if
river=
0
and
glake=
0
then
do;
fish300m
=
462.438;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
9.173;
end;

ramp=
0;
ln_
acre=
0;
ln_
lndac=
0;
fish=
0;
beach=
0;
dock=
0;
boatrent=
0;
awqc_
ex=
0;
park=
0;
amm=
0;
bod=
0;
iwb2=
0;
nit=
0;
oil=
0;
phos=
0;
tss=
0;
tot_
n=
0;
iwb2=
0;
fuel=
0;
motor=
0;
sailing=
0;
own_
boat=
0;
boat_
use=
0;
picnic=
0;
nij=
40;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
full_
id
respnum
rf1id
price1
price2
ramp
ln_
acre
ln_
lndac
asc
own_
boat
boat_
use
fish
beach
dock
picnic
glake
fuel
motor
sailing
nij
visitdm
visits
obnum
kids6
new_
tox
awqc_
ex
park
rch_
len
rch_
wid
river
trpcost
timcost
age
income
ln_
inc
amm
bod
nit
oil
phos
tkn
tss
tot_
n
iwb2
rchsze
fisher
swimer
boater
viewer
college
house_
sz
boat_
use
rnt_
boat
tow_
boat
mor_
boat
fish300m
fish100m
fish1m
wgt_
300m
ds
wage
unempl
home_
mk
retired
paid_
cst
car
share;
run;

/***********************************************/
/*
CREATE
OUTPUT
DATASET
WITH
SELECT
VARIABLES
*/
/***********************************************/

proc
sort
data=
initial;
by
full_
id
obnum;
quit;
45
data
rand.&
finalSet;
set
initial;
run;
46
"
Swimming
Model
Glake
Split
3_
20_
02.
sas"
Randomly
draws
designated
swimming
sites
within
a
radius
from
the
participants
home.
The
choice
set
is
matched
with
demographic
data
from
the
respondent
and
a
data
set
is
created.
47
/*

PROGRAM:
Swimming
Model
Glake
Split
3_
20_
02.
sas
AUTHORS:
Stuart
Smith
&
Mike
Needleman
&
George
Parsons
*/
/*****************************************************************************/
/*
CITATION
OF
ORIGINAL
PROGRAM
CODE
*/
/*****************************************************************************/
/*
*/
/*
The
original
form
of
this
random
draw
program
was
*/
/*
created
by
Mike
Needleman
and
George
Parsons
at
the
University
of
*/
/*
Delaware
under
a
U.
S.
EPA
cooperative
agreement
for
Measuring
the
*/
/*
Benefits
of
Water
Quality
Improvements.
*/
/*****************************************************************************/

/*****************************************************************************/
/*
MODIFICATIONS
TO
THE
ORIGINAL
CODE
*/
/*****************************************************************************/
/*
*/
/*
Few
variable
names
remain
unchanged.
The
majority
of
variable
names
*/
/*
have
been
changed
to
reflect
the
current
application.
An
additional
*/
/*
routine
RESETIT
was
created
by
Stuart
Smith.
In
addition,
changes
to
*/
/*
the
drawing
criteria
as
well
as
links
to
the
water
quality
data
for
*/
/*
purposes
of
the
random
draw
have
been
added
or
modified
from
the
*/
/*
original
program
code.
All
modifications
have
been
made
by
Stuart
*/
/*
Smith,
an
employee
of
Abt
Associates.
*/
/*****************************************************************************/

/*
REVISION
DATE:
3/
20/
2002
SWIMMERS
Sites
are
drawn
on
the
following
criteria:

1)
the
site
is
within
the
distance
traveled
to
the
chosen
site
or
120
miles,
whichever
is
greater.
2)
the
site
is
not
the
chosen
site
*/

libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
draw=
40;
%
let
activity=
swimer;
%
let
distmax=
120;
%
let
finalSet=
swimg320;

/*
Setup
ouput
dataset
*/
48
data
randrch
(
keep
=
full_
id
siteid
rch1­
rch&
draw
dst1­
dst&
draw);

/*
Initialize
arrays
for
draw
construction
*/
/*
Chosen
site,
39
random
draws
*/
array
rch{*}
rch1­
rch&
draw;
array
dst{*}
dst1­
dst&
draw;
array
norepl{*}
norepl1­
norepl&
draw;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
set
demogr.
fullset2;

/*
Drop
non
fishermen,
we
don't
need
them
here.
*/

if
&
activity
=
0
then
delete;

/*
Drop
non­
matched
*/

if
siteid
=
0
then
put
'
NOT
MATCHED
TO
A
SITE!!!
Respnum
=
'
respnum;
if
siteid
=
0
then
delete;

visitid=
siteid;

/*
Convert
zipcode
to
row
number
in
the
distance
matrix.
The
matrix
contains
one
row
for
each
respondent
zipcode.
The
zip_
fmt
translates
the
zipcode
into
its
corresponding
row
number
in
the
distance
matrix
(
1­
337)
*/

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
rchdist{
1954}
_
1­_
1954;
array
c{
4}
c1­
c4;
array
count{
1954}
cnt1­
cnt1954;

set
lori.
matrix4
point=
zipid;

do
l
=
1
to
&
draw;
norepl{
l}=
0;
end;

c1=
0;
lori=
0;

/*
Obtain
the
chosen
reach
id
number
*/
if
visitid
^=
999
then
do;
/*
Chose
site
within
Ohio
*/
rchid=
visitid;
newrchid=
rchid;
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!
Respnum
'
respnum
'
SITE:
'
rchid;
if
dsta
=
9999
then
delete;
set
reach.
rch_
info
point=
dsta;
if
glake
=
1
then
do;
/*
is
chosen
site
a
great
lake
site?
*/
49
k=
1;
strt1=
2;
end1=
20;
strt2=
21;
end2=
40;
end;
if
glake
=
0
then
do;
/*
not
a
great
lake
for
chosen
site
*/
k=
21;
strt1=
1;
end1=
20;
strt2=
22;
end2=
40;
end;
link
chosen;
chdist=
dst(
k);
end;
/*
chosen
site
is
within
Ohio
*/
else
delete;

if
visitid
=
0
then
delete;

/*************************************/
/*
MACRO
­
to
build
selected
sets
*/
/*************************************/

%
macro
buildset(
strt=,
ennd=,
cnt=,
maxd=,
boating=,
crit=);

do
k
=
&
strt
to
&
ennd;
if
k
=
&
strt
then
do;
do
until
(
lori=
1954);
lori=
lori+
1;
link
reachit;
set
reach.
rch_
info
point=
lori;
/*
point
to
reach
row
in
water
data
*/
trip=
max(
chdist,&
maxd);
if
&
boating=
1
then
do;
if
ramp=
1
or
boatrent=
1
or
dock=
1
or
sailbt=
1
then
boatable=
1;
else
boatable=
0;
end;
if
&
crit
then
do;
c(
1)
=
c(
1)
+
1;
count(
c(
1))
=
lori;
end;
/*
if
criteria
*/
end;
/*
do
until
*/
end;
/*
if
k=&
strt
*/
start=
1;
range=
1;
if
c(
1)
<
&
cnt­
1
then
do;
if
k
<=
(
c(
1)+
1)
then
do;
lori=
count(
k­
1);
link
reachit;
end;
else
do;
50
dst(
k)=.;
rch(
k)=.;
end;
/*
else
do
*/
end;
else
link
rndset;
end;
/*
do
k=&
strt
to
&
ennd
*/
link
resetit;

%
mend
buildset;

/*************************************/
/*
END
MACRO
­
to
build
selected
sets*/
/*************************************/

/*
Call
macro
for
each
nest
to
build
the
sets
*/

%
buildset(
strt=
strt1,
ennd=
end1,
cnt=
end1,
maxd=
300,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
glake=
1));
%
buildset(
strt=
strt2,
ennd=
end2,
cnt=
end1,
maxd=&
distmax,
boating=
0,
crit=(
rch(
k)
^=
newrchid)
&
(
dst(
k)
<=
trip)
&
(
glake=
0));

output;
link
resetit;
goto
end;

/********************************************************************/
/*
CODE
ROUTINES
FOR
BULDING
THE
CHOICE
SET
*/
/********************************************************************/

/*
Takes
the
lori
index
number
(
1­
1954)
and
translates
it
into
a
reachid
number
*/
reachit:
rchid
=
put(
lori,
lori_
fmt.);
if
rchid
=
9999
then
put
'
REACH
ID
MISMATCH!!!';

/*
Translates
the
reachid
number
into
its
sequence
number
which
corresponds
to
the
variable
in
the
distance
matrix
containing
the
distance
from
the
zipcode
to
that
reach.
*/
chosen:
dsta=
input(
put(
rchid,
rch_
fmt.),
4.);
if
dsta
=
9999
then
put
'
DSTA
MISMATCH!!!';
dst(
k)
=
rchdist(
dsta);
rch(
k)
=
rchid;
return;

/*
Take
the
full
set
of
possible
reaches
and
randomly
select
a
subset
of
those
possible
sites.
Size
of
random
draw
is
controled
by
the
size
of
the
initial
rch
array.
*/
rndset:
if
c(
range)
>
0
then
do;
relori:
lori
=
int(
ranuni(
0)
*
c(
range));
51
if
lori
=
0
then
lori
=
c(
range);
lori
=
count(
lori);
do
i
=
start
to
k­
1;
if
norepl(
i)
=
lori
then
goto
relori;
end;
norepl(
k)
=
lori;
link
reachit;
end;
else
do;
dst(
k)=.;
rch(
k)=.;
end;
return;

/*
Reset
the
necessary
variables
to
zero
for
the
next
respondent.
*/
resetit:
do
i
=
1
to
&
draw;
norepl{
i}=
0;
end;
do
i
=
1
to
1954;
count{
i}=
0;
end;
c1=
0;
lori=
0;
cold=
0;
coldrch=
0;
chdist=
0;
miss=
0;
return;

end:
run;

/*
End
of
Random
Draw
program
code
*/

proc
print
data=
randrch;
format
rch1­
rch&
draw
13.2
siteid
13.2;
quit;

/*
The
following
section
adds
the
remaining
demographic
data
and
water
quality
data.
It
also
twists
the
data
into
a
limdep
fashion
dataset.
*/

/*****************************************************************************
*
GET
DEMOGRAHIC
DATA
*
*****************************************************************************/

data
evryone;
set
demogr.
fullset2;
if
&
activity=
1;

/****************************************************************************
*
GET
INFORMATION
FROM
RANDOM
DATA
SETS
*
****************************************************************************/
52
data
random;
set
randrch;

/****************************************************************************
*
MERGE
DEMOGRAPHICS
AND
RANDOM
*
****************************************************************************/

proc
sort
data=
random;
by
full_
id
siteid;

proc
sort
data=
evryone;
by
full_
id
siteid;

data
combine;
merge
evryone
random;
by
full_
id
siteid;

/****************************************************************************
*
PREPARE
FILE
FOR
LIMDEP
*
*****************************************************************************/

data
concat;
set
combine;
array
reach{&
draw}
rch1­
rch&
draw;
array
dist{&
draw}
dst1­
dst&
draw;
do
I=
1
to
&
draw;
lk=
reach{
I};
ds=
dist{
I};
if
ds=
0
and
lk
^=
999
then
ds=.
5;
/*
Keep
0
distance
for
outside
Ohio
sites
*/
output;
end;

/*****************************************************************************
*
CALCULATE
VISITDM
VARIABLE
*
******************************************************************************/

data
here;
set
concat;
drop
rch1­
rch&
draw
dst1­
dst&
draw;

/*
Delete
records
within
a
individual's
opportunity
set
for
which
there
were
no
lakes
available.
*/

if
lk='.'
then
delete;

/*
This
visitdm
variable
is
only
for
the
lakes,
it
does
not
work
for
the
no
trip
lines
*/

if
lk=
siteid
then
visitdm=
1;
else
visitdm=
0;
obnum=_
n_;
53
/*****************************************************************************
*
OUTPUT
DATA
SET
*
******************************************************************************/

data
twst;
set
here;
if
full_
id
=
.
then
delete;

proc
sort
data=
twst;
by
full_
id
lk;
quit;

/*
Read
in
the
raw
data
*/

data
initial;
set
twst(
rename=(
lk=
rf1id));

/*
Calc
for
real
sites
*/

if
rf1id
=
999
then
skipit
=
1;
else
skipit
=
0;

if
skipit=
0
then
do;
ind=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
ind=
9999
then
put
'
REACH
MISMATCH!!!!';

set
reach.
rch_
info
point=
ind;
/*
site
attribute
data
*/

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Create
Cost
of
trip
variables
*/

op_
cost=(
wage*(
ds/
40))*
2;
tr_
cost=(((
ds*
0.29*
paid_
cst*
car)/
share))*
2;

price1=
0.5*
op_
cost
+
tr_
cost;
price2=
0.33*
op_
cost
+
tr_
cost;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

tot_
n
=
nit
+
tkn;
nij=
40;
asc
=
0;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/
54
if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

end;
/*
Skipit
=
0
*/

/*
Set
variables
for
sites
outside
Ohio
*/
if
skipit
=
1
then
do;
set
reach.
outstate
point=
outlink;
if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/

if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds*
2
+
(
wage*(
ds/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds/
40)*
2;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
segl
^=
0
then
rchsze=
log(
segl);
55
else
rchsze
=
0;
end;
else
do;
/*
small
lakes
*/
if
ln_
acre=.
then
ln_
acre=
0;
pi
=
3.141592654;
area
=
segl**
2;
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
river=
1
then
do;
fish300m
=
461.366;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
6.519;
end;
if
glake=
1
then
do;
fish300m
=
198.313;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
5.021;
end;
if
river=
0
and
glake=
0
then
do;
fish300m
=
462.438;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;
wght300m
=
9.173;
end;

ramp=
0;
ln_
acre=
0;
ln_
lndac=
0;
fish=
0;
beach=
0;
dock=
0;
boatrent=
0;
awqc_
ex=
0;
park=
0;
amm=
0;
bod=
0;
iwb2=
0;
nit=
0;
oil=
0;
phos=
0;
tss=
0;
tot_
n=
0;
iwb2=
0;
fuel=
0;
motor=
0;
sailing=
0;
own_
boat=
0;
boat_
use=
0;
picnic=
0;
nij=
40;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
full_
id
respnum
rf1id
price1
price2
ramp
ln_
acre
ln_
lndac
asc
own_
boat
boat_
use
fish
beach
dock
picnic
glake
fuel
motor
sailing
nij
visitdm
visits
obnum
kids6
new_
tox
awqc_
ex
park
rch_
len
rch_
wid
river
trpcost
timcost
age
income
ln_
inc
56
amm
bod
nit
oil
phos
tkn
tss
tot_
n
iwb2
rchsze
fisher
swimer
boater
viewer
college
house_
sz
boat_
use
rnt_
boat
tow_
boat
mor_
boat
fish300m
fish100m
fish1m
wgt_
300m
ds
wage
unempl
home_
mk
retired
paid_
cst
car
share;
run;

/***********************************************/
/*
CREATE
OUTPUT
DATASET
WITH
SELECT
VARIABLES
*/
/***********************************************/

proc
sort
data=
initial;
by
full_
id
obnum;
quit;

data
rand.&
finalSet;
set
initial;
run;
57
Estimate
the
Site
Choice
Models
in
Limdep
58
"
Run
Random
Fish
Draws.
lim"
Estimates
a
nested
logit
model
of
fishing
site
choice
for
data
sets
based
on
five
random
draws.
59
?
Program:
Run
Random
Fish
Draws.
lim
?
Author:
Stuart
Smith
?
Date:
4.22.02
?
Draw
0
?
RUN
THE
DATA
FILE
?
Project
must
be
loaded
?
ESTIMATE
THE
MODEL
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$

Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/

U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
W[
1]*
rwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
fish_
wb.
txt"$
60
?
RESET
RESET$

?
Draw
1
?
RUN
THE
DATA
FILE
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBType
Split
1.
lpj"$

?
ESTIMATE
THE
MODEL
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost
=
0.29*
ds*
2
;
timcost
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$

Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/

U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
W[
1]*
rwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
fish_
wb1.
txt"$
61
?
RESET
RESET$

?
Draw
2
?
RUN
THE
DATA
FILE
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBType
Split
2.
lpj"$

?
ESTIMATE
THE
MODEL
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost
=
0.29*
ds*
2
;
timcost
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$

Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/

U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
W[
1]*
rwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
fish_
wb2.
txt"$
62
?
RESET
RESET$

?
Draw
3
?
RUN
THE
DATA
FILE
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBType
Split
3.
lpj"$

?
ESTIMATE
THE
MODEL
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost
=
0.29*
ds*
2
;
timcost
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$

Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/

U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
W[
1]*
rwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
fish_
wb3.
txt"$
63
?
RESET
RESET$

?
Draw
4
?
RUN
THE
DATA
FILE
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBType
Split
4.
lpj"$

?
ESTIMATE
THE
MODEL
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost
=
0.29*
ds*
2
;
timcost
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$

Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/

U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
W[
1]*
rwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
fish_
wb4.
txt"$
64
Program
Output
65
­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBTy...
.
LPJ
save
file
contained
5040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/
U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
...
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
5040
|
|
Iterations
completed
24
|
|
Log
likelihood
function
­
1202.850
|
|
Restricted
log
likelihood
­
2268.267
|
|
Chi
squared
2130.834
|
|
Degrees
of
freedom
12
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
2268.2669
.46971
.46842
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
2291.0287
.47497
.47370
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
66
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
84,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4458235959E­
01
.19498348E­
02
­
23.501
.0000
TMCOST
­
1.222580745
.16982129
­
7.199
.0000
RMP
1.041479162
.12505302
8.328
.0000
LNGSIZE
.6963248623
.15780358
4.413
.0000
TKNP
­.
3897156156
.15074140
­
2.585
.0097
AWQC
­.
3512130391
.15418551
­
2.278
.0227
W
1.000000000
........(
Fixed
Parameter)........
LNRSIZE
.8412337993E­
02
.90261920E­
01
.093
.9257
FWGHT_
R
.6803573662E­
01
.29363353E­
01
2.317
.0205
LNLSIZE
.7404892723
.38820552
1.907
.0565
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.6772327236
.69576170E­
01
9.734
.0000
RIV
.4748312941
.94459684E­
01
5.027
.0000
LAKE
.6408882476E­
01
.14759771
.434
.6641
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBTy...
.
LPJ
save
file
contained
5040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/
U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
...
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
67
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
5040
|
|
Iterations
completed
25
|
|
Log
likelihood
function
­
1221.313
|
|
Restricted
log
likelihood
­
2268.267
|
|
Chi
squared
2093.908
|
|
Degrees
of
freedom
12
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
2268.2669
.46157
.46026
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
2291.0287
.46692
.46562
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
84,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
3971454312E­
01
.18119983E­
02
­
21.918
.0000
TMCOST
­
1.617184473
.20984156
­
7.707
.0000
RMP
.9475842414
.11598774
8.170
.0000
LNGSIZE
.7873481152
.13315306
5.913
.0000
TKNP
­.
6133485360
.15249677
­
4.022
.0001
AWQC
­.
6683311258
.15432839
­
4.331
.0000
W
1.000000000
........(
Fixed
Parameter)........
LNRSIZE
.1864567669
.88292829E­
01
2.112
.0347
FWGHT_
R
.5215352006E­
01
.28524884E­
01
1.828
.0675
LNLSIZE
­.
3891252873E­
01
.13980787
­.
278
.7808
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.9725364980
.10112270
9.617
.0000
RIV
.6287464957
.86991176E­
01
7.228
.0000
LAKE
.4999842498
.16905960
2.957
.0031
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBTy...
.
LPJ
save
file
contained
5040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
68
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/
U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
...
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
5040
|
|
Iterations
completed
23
|
|
Log
likelihood
function
­
1191.605
|
|
Restricted
log
likelihood
­
2268.267
|
|
Chi
squared
2153.324
|
|
Degrees
of
freedom
12
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
2268.2669
.47466
.47339
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
2291.0287
.47988
.47862
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
84,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
69
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4515586676E­
01
.19403947E­
02
­
23.271
.0000
TMCOST
­
1.383427578
.18304041
­
7.558
.0000
RMP
.7339254795
.11747454
6.248
.0000
LNGSIZE
1.019901963
.12640253
8.069
.0000
TKNP
­.
6471211063
.14665787
­
4.412
.0000
AWQC
­.
5901956713
.16012246
­
3.686
.0002
W
1.000000000
........(
Fixed
Parameter)........
LNRSIZE
.3576124043
.99815579E­
01
3.583
.0003
FWGHT_
R
.2574248897E­
01
.27783012E­
01
.927
.3542
LNLSIZE
­.
2128715855
.11402914
­
1.867
.0619
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.8482709724
.82920121E­
01
10.230
.0000
RIV
.6033494162
.75537371E­
01
7.987
.0000
LAKE
.5496054007
.13607797
4.039
.0001
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBTy...
.
LPJ
save
file
contained
5040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/
U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
...
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
70
|
Weighting
variable
VISITS
|
|
Number
of
observations
5040
|
|
Iterations
completed
23
|
|
Log
likelihood
function
­
1206.182
|
|
Restricted
log
likelihood
­
2268.267
|
|
Chi
squared
2124.169
|
|
Degrees
of
freedom
12
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
2268.2669
.46824
.46695
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
2291.0287
.47352
.47224
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
84,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4664669013E­
01
.21246729E­
02
­
21.955
.0000
TMCOST
­
1.441662213
.19142439
­
7.531
.0000
RMP
.8209476745
.10948037
7.499
.0000
LNGSIZE
1.022122330
.14170600
7.213
.0000
TKNP
­.
7010138234
.16328840
­
4.293
.0000
AWQC
­.
5259297643
.15358705
­
3.424
.0006
W
1.000000000
........(
Fixed
Parameter)........
LNRSIZE
.5514671054E­
02
.70238850E­
01
.079
.9374
FWGHT_
R
.1897645484E­
01
.27981606E­
01
.678
.4977
LNLSIZE
­.
1012640419
.15459764
­.
655
.5125
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.7252067194
.73035258E­
01
9.930
.0000
RIV
.6667257415
.86240630E­
01
7.731
.0000
LAKE
.4667867764
.17396194
2.683
.0073
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
WBTy...
.
LPJ
save
file
contained
5040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.411
;
rwght
=
4.445
;
lwght
=
2.128
;
intramp
=
ramp*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
timcost1
=
(
ds/
40)*
2*
wage*
0.5
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
sqiwb
=
sqr(
iwb2)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
71
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
ERIE(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
RIV(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20),
LAKE(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lngSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght/
U(
r1,
r2,
r3,
r4,
r5,
r6,
r7,
r8,
r9,
r10,
r11,
r12,
r13,
r14,
r15,
r16,
r17,
r18,
r19,
r20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnrSize*
rchsze
+
TKNp*
tkn
+
Awqc*
awqc_
ex
+
fwght_
r*
sqrwgt
+
...
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
Rmp*
ramp
+
lnlSize*
rchsze
+
W[
1]*
lwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
5040
|
|
Iterations
completed
26
|
|
Log
likelihood
function
­
1203.522
|
|
Restricted
log
likelihood
­
2268.267
|
|
Chi
squared
2129.490
|
|
Degrees
of
freedom
12
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
2268.2669
.46941
.46812
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
2291.0287
.47468
.47341
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
84,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4563902846E­
01
.19952295E­
02
­
22.874
.0000
TMCOST
­
1.706825071
.23024114
­
7.413
.0000
RMP
.8443516369
.11567360
7.299
.0000
LNGSIZE
1.015727992
.13390573
7.585
.0000
TKNP
­.
5712093761
.16296491
­
3.505
.0005
AWQC
­.
7292679627
.15283026
­
4.772
.0000
W
1.000000000
........(
Fixed
Parameter)........
LNRSIZE
.2951959139
.71999677E­
01
4.100
.0000
72
FWGHT_
R
.1739349564
.29534565E­
01
5.889
.0000
LNLSIZE
­.
1391578868
.16407015
­.
848
.3963
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.8325466979
.83555124E­
01
9.964
.0000
RIV
.5815896846
.86130959E­
01
6.752
.0000
LAKE
.5629029147
.18557850
3.033
.0024
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)
73
"
Run
Random
Draws
for
Boating.
lim"
Estimates
a
nested
logit
model
of
boating
site
choice
for
data
sets
based
on
five
random
draws.
74
?
Author:
Stuart
Smith
?
Program:
Run
Random
Draws
for
Boating.
lim
?
Date:
4/
22/
2002
?
Draw
0
?
Project
must
already
be
loaded
?
Estimate
model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
boat0.
txt"$

?
RESET
RESET$

?
Draw
1
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Glake
Inland
Split
1.
lpj"$

?
Estimate
model
create
75
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
boat1.
txt"$

?
RESET
RESET$

?
Draw
2
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Glake
Inland
Split
2.
lpj"$

?
Estimate
model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
76
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
boat2.
txt"$

?
RESET
RESET$

?
Draw
3
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Glake
Inland
Split
3.
lpj"$

?
Estimate
model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
77
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
boat3.
txt"$

?
RESET
RESET$

?
Draw
4
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Glake
Inland
Split
4.
lpj"$

?
Estimate
model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
78
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
boat4.
txt"$

?
RESET
RESET$
79
Program
Output
80
­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Glak...
.
LPJ
save
file
contained
2560
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
...
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
2560
|
|
Iterations
completed
17
|
|
Log
likelihood
function
­
996.6648
|
|
Restricted
log
likelihood
­
1364.885
|
|
Chi
squared
736.4413
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1364.8854
.26978
.26743
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1271.5112
.21616
.21364
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
64,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
81
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434797600E­
01........(
Fixed
Parameter)........
TMCOST
­.
2550168144
.80752301E­
01
­
3.158
.0016
FSHWGTG
­.
1040885461
.69189685E­
01
­
1.504
.1325
LNSIZE
.6815398382
.90106259E­
01
7.564
.0000
TKN
­
1.226267377
.17012969
­
7.208
.0000
AWQC
­.
6398159813
.14589525
­
4.385
.0000
W
1.000000000
........(
Fixed
Parameter)........
FSHWGTR
­.
6201672993E­
01
.33928432E­
01
­
1.828
.0676
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.3302432411
.51531608E­
01
6.409
.0000
INLND
.1367457666
.37400018E­
01
3.656
.0003
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
RESET$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Gl...
.
LPJ
save
file
contained
2560
observations.
­­>
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
...
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
2560
|
|
Iterations
completed
18
|
|
Log
likelihood
function
­
998.6983
|
|
Restricted
log
likelihood
­
1364.885
|
|
Chi
squared
732.3741
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1364.8854
.26829
.26594
|
|
Constants
only.
Must
be
computed
directly.
|
82
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1260.8970
.20795
.20540
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
64,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434797600E­
01........(
Fixed
Parameter)........
TMCOST
­.
3468383937
.81185076E­
01
­
4.272
.0000
FSHWGTG
­.
8399836055E­
01
.76393577E­
01
­
1.100
.2715
LNSIZE
.2753658009
.88907934E­
01
3.097
.0020
TKN
­
1.265115627
.17818338
­
7.100
.0000
AWQC
.1287521472
.13589825
.947
.3434
W
1.000000000
........(
Fixed
Parameter)........
FSHWGTR
.5483862361E­
01
.37373468E­
01
1.467
.1423
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.2828220656
.48520262E­
01
5.829
.0000
INLND
.7106757511E­
01
.37851670E­
01
1.878
.0604
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
RESET$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Gl...
.
LPJ
save
file
contained
2560
observations.
­­>
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
...
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
83
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
2560
|
|
Iterations
completed
17
|
|
Log
likelihood
function
­
987.6983
|
|
Restricted
log
likelihood
­
1364.885
|
|
Chi
squared
754.3741
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1364.8854
.27635
.27402
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1259.1886
.21561
.21309
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
64,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434797600E­
01........(
Fixed
Parameter)........
TMCOST
­.
3735999672
.78702170E­
01
­
4.747
.0000
FSHWGTG
­.
1370604348
.72516734E­
01
­
1.890
.0588
LNSIZE
.6160864128
.86574259E­
01
7.116
.0000
TKN
­
1.063637281
.17197943
­
6.185
.0000
AWQC
­.
2915086930
.14093410
­
2.068
.0386
W
1.000000000
........(
Fixed
Parameter)........
FSHWGTR
­.
1145593182E­
01
.38097889E­
01
­.
301
.7636
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.3093061821
.49607652E­
01
6.235
.0000
INLND
.1067987233
.32732673E­
01
3.263
.0011
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
RESET$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Gl...
.
LPJ
save
file
contained
2560
observations.
­­>
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
84
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
...
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
2560
|
|
Iterations
completed
18
|
|
Log
likelihood
function
­
937.5488
|
|
Restricted
log
likelihood
­
1364.885
|
|
Chi
squared
854.6733
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1364.8854
.31309
.31088
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1235.6325
.24124
.23880
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
64,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434797600E­
01........(
Fixed
Parameter)........
TMCOST
­.
4848390343
.90329929E­
01
­
5.367
.0000
FSHWGTG
­.
1668387163
.72523539E­
01
­
2.300
.0214
LNSIZE
.6247378557
.86378195E­
01
7.233
.0000
TKN
­
1.210590886
.19162654
­
6.317
.0000
AWQC
­.
1367269828
.13999655
­.
977
.3287
W
1.000000000
........(
Fixed
Parameter)........
FSHWGTR
.1368226975E­
01
.35452044E­
01
.386
.6995
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.2807257320
.44257885E­
01
6.343
.0000
85
INLND
.6468201115E­
01
.31861177E­
01
2.030
.0423
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
RESET$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Gl...
.
LPJ
save
file
contained
2560
observations.
­­>
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
1.17
;
rwght
=
3.183
;
intdock
=
dock*
own_
boat
;
trpcost1
=
0.29*
ds*
2
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.044347976]*
trpcost
+
TmCost*
timcost
+
fshwgtg*
sqgwgt
...
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
fshwgtr*
sqrwgt
+
lnSize*
rchsze
+
TKN*
tkn
+
Awqc*
awqc_
ex
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
2560
|
|
Iterations
completed
19
|
|
Log
likelihood
function
­
976.0246
|
|
Restricted
log
likelihood
­
1364.885
|
|
Chi
squared
777.7217
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1364.8854
.28490
.28260
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1254.0315
.22169
.21919
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
86
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
64,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434797600E­
01........(
Fixed
Parameter)........
TMCOST
­.
3485360355
.91600484E­
01
­
3.805
.0001
FSHWGTG
­.
1559323614
.74595348E­
01
­
2.090
.0366
LNSIZE
.3117176853
.80484804E­
01
3.873
.0001
TKN
­
1.170205476
.15597409
­
7.503
.0000
AWQC
.8069152217E­
01
.13721223
.588
.5565
W
1.000000000
........(
Fixed
Parameter)........
FSHWGTR
.8872907751E­
01
.35601580E­
01
2.492
.0127
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.2759882699
.48655488E­
01
5.672
.0000
INLND
.6208483954E­
01
.34521647E­
01
1.798
.0721
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
RESET$
87
"
Run
Random
Draws
for
Viewing
Model.
lim"
Estimates
a
nested
logit
model
of
viewing
site
choice
for
data
sets
based
on
five
random
draws.
88
?
Author:
Stuart
Smith
?
Program:
Run
Random
Draws
for
Viewing
Model.
lim
?
Date:
4/
22/
2002
?
Draw
0
?
Make
sure
project
is
already
loaded
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$

?
Estimate
the
Logit
Model
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
view0.
txt"$

?
Reset
Reset$

?
Draw
1
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewing
Model
1.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$

?
Estimate
the
Logit
Model
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
89
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
view1.
txt"$

?
Reset
Reset$

?
Draw
2
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewing
Model
2.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$

?
Estimate
the
Logit
Model
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
view2.
txt"$

?
Reset
Reset$

?
Draw
3
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewing
Model
3.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$

?
Estimate
the
Logit
Model
90
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
view3.
txt"$

?
Reset
Reset$

?
Draw
4
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewing
Model
4.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$

?
Estimate
the
Logit
Model
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
view4.
txt"$

?
Reset
Reset$
91
Program
Output
92
­­>
RESET
­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewing...
.
LPJ
save
file
contained
2920
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$
­­>
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Discrete
choice
(
multinomial
logit)
model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
Choice
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
73
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
1157.040
|
|
Log­
L
for
Choice
model
=
­
1157.04049
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
Response
data
are
given
as
ind.
choice.
|
|
Number
of
obs.=
73,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
TRPCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TIMCOST
­.
7761635784
.60773485E­
01
­
12.771
.0000
GSZE
.6147193151
.55068390E­
01
11.163
.0000
RSZE
­.
3202664978
.50681030E­
01
­
6.319
.0000
LSZE
­.
3864969568
.10107402
­
3.824
.0001
LN_
LNDAC
.1391460011
.21318000E­
01
6.527
.0000
TKN
­.
8225994526
.18650809
­
4.411
.0000
PARK
1.017167122
.17082019
5.955
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewi...
.
LPJ
save
file
contained
2920
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
93
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$
­­>
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Discrete
choice
(
multinomial
logit)
model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
Choice
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
73
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
1128.540
|
|
Log­
L
for
Choice
model
=
­
1128.53986
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
Response
data
are
given
as
ind.
choice.
|
|
Number
of
obs.=
73,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
TRPCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TIMCOST
­.
7558383044
.59381125E­
01
­
12.729
.0000
GSZE
.6708880878
.65862098E­
01
10.186
.0000
RSZE
­.
1337282452
.49263402E­
01
­
2.715
.0066
LSZE
­.
6659299992
.11059877
­
6.021
.0000
LN_
LNDAC
.1776121532
.21520749E­
01
8.253
.0000
TKN
­.
5485653595
.16301139
­
3.365
.0008
PARK
.1822740861
.17022745
1.071
.2843
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewi...
.
LPJ
save
file
contained
2920
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$
­­>
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Discrete
choice
(
multinomial
logit)
model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
Choice
|
|
Weighting
variable
VISITS
|
94
|
Number
of
observations
73
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
1174.323
|
|
Log­
L
for
Choice
model
=
­
1174.32254
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
Response
data
are
given
as
ind.
choice.
|
|
Number
of
obs.=
73,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
TRPCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TIMCOST
­.
7236258768
.56442216E­
01
­
12.821
.0000
GSZE
.5824568313
.63162200E­
01
9.222
.0000
RSZE
­.
2111683533
.45702618E­
01
­
4.620
.0000
LSZE
­.
3666466614
.90599828E­
01
­
4.047
.0001
LN_
LNDAC
.2616043582
.23028643E­
01
11.360
.0000
TKN
­.
9554865576
.14476453
­
6.600
.0000
PARK
.6285499330E­
01
.19298006
.326
.7446
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewi...
.
LPJ
save
file
contained
2920
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$
­­>
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Discrete
choice
(
multinomial
logit)
model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
Choice
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
73
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
1140.182
|
|
Log­
L
for
Choice
model
=
­
1140.18151
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
Response
data
are
given
as
ind.
choice.
|
|
Number
of
obs.=
73,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
TRPCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
95
TIMCOST
­.
6757611498
.54346867E­
01
­
12.434
.0000
GSZE
.6572011355
.62226161E­
01
10.561
.0000
RSZE
­.
4012071387
.59736386E­
01
­
6.716
.0000
LSZE
­.
6066021214
.91253285E­
01
­
6.647
.0000
LN_
LNDAC
.9121505573E­
01
.21452455E­
01
4.252
.0000
TKN
­.
5892075703
.15521354
­
3.796
.0001
PARK
1.297711743
.17538025
7.399
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Flat
Viewi...
.
LPJ
save
file
contained
2920
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
trpcost1
=
0.29*
ds*
2
;
gsze
=
glake*
rchsze
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)
;
numalt=
40$
­­>
nlogit;
Lhs
=
visitdm,
numalt
;
Rhs
=
trpcost,
timcost,
gsze,
rsze,
lsze,
ln_
lndac,
tkn,
park
;
Fix
=
trpcost[­
0.0443476976]
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Discrete
choice
(
multinomial
logit)
model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
Choice
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
73
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
1089.520
|
|
Log­
L
for
Choice
model
=
­
1089.51964
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
Response
data
are
given
as
ind.
choice.
|
|
Number
of
obs.=
73,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
TRPCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TIMCOST
­.
6653941840
.53323679E­
01
­
12.478
.0000
GSZE
.8020944472
.71378956E­
01
11.237
.0000
RSZE
­.
2369727391
.54943339E­
01
­
4.313
.0000
LSZE
­.
1202478583
.10893161
­
1.104
.2696
LN_
LNDAC
.1407957167
.20226543E­
01
6.961
.0000
TKN
­.
6404882299
.16705361
­
3.834
.0001
PARK
1.375377091
.16298225
8.439
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
Reset$
96
97
"
Run
Random
Draws
for
Swimming
Model.
lim"
Estimates
a
flat
logit
model
of
swimming
site
choice
for
data
sets
based
on
seven
random
draws.
98
?
Author:
Stuart
Smith
?
Program:
Run
Random
Draws
for
Swimming
Model.
lim
?
Date:
4/
22/
2002
?
Draw
0
?
Make
sure
project
is
already
loaded
?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
swim0.
txt"$

?
Reset
Reset$

?
Draw
1
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Glake
Inland
Split
1.
lpj"$

?
Estimate
Model
99
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
swim1.
txt"$

?
Reset
Reset$

?
Draw
2
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Glake
Inland
Split
2.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
100
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
swim2.
txt"$

?
Reset
Reset$

?
Draw
3
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Glake
Inland
Split
3.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
101
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)

=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
swim3.
txt"$

?
Reset
Reset$

?
Draw
4
?
Load
the
project
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Glake
Inland
Split
4.
lpj"$

?
Estimate
Model
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$

?
Estimate
the
Logit
Model
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:

U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
102
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/

U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)

=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
beach*
beach
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$

Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estimates
­
testing
trip
prediction\
swim4.
txt"$

?
Reset
Reset$
103
Program
Output
104
­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Gla...
.
LPJ
save
file
contained
3040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
3040
|
|
Iterations
completed
15
|
|
Log
likelihood
function
­
1090.379
|
|
Restricted
log
likelihood
­
1885.017
|
|
Chi
squared
1589.278
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1885.0174
.42156
.41999
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1343.1254
.18818
.18598
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
76,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
105
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TMCOST
­.
6223192588
.71800278E­
01
­
8.667
.0000
LAND
.1005802645
.22722121E­
01
4.427
.0000
PARK
.6767469389
.18296672
3.699
.0002
BEACH
.8354039347
.16126562
5.180
.0000
SIZE
­.
3040525593
.44134444E­
01
­
6.889
.0000
TKNP
­.
4772258430
.14063948
­
3.393
.0007
W
1.000000000
........(
Fixed
Parameter)........
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.6630463125
.85818335E­
01
7.726
.0000
INLND
.2800069111
.40270898E­
01
6.953
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
Reset$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
G...
.
LPJ
save
file
contained
3040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
3040
|
|
Iterations
completed
15
|
|
Log
likelihood
function
­
1119.079
|
|
Restricted
log
likelihood
­
1885.017
|
|
Chi
squared
1531.878
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
106
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1885.0174
.40633
.40472
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1362.7897
.17883
.17661
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
76,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TMCOST
­.
4254247538
.64766507E­
01
­
6.569
.0000
LAND
.7479737203E­
01
.24855042E­
01
3.009
.0026
PARK
1.085091654
.20119416
5.393
.0000
BEACH
­.
1132367096
.18501049
­.
612
.5405
SIZE
­.
1740261949
.37621220E­
01
­
4.626
.0000
TKNP
­.
5890847246
.14333462
­
4.110
.0000
W
1.000000000
........(
Fixed
Parameter)........
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.6355999239
.81609585E­
01
7.788
.0000
INLND
.2658201844
.38237706E­
01
6.952
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
G...
.
LPJ
save
file
contained
3040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
107
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
3040
|
|
Iterations
completed
16
|
|
Log
likelihood
function
­
1091.513
|
|
Restricted
log
likelihood
­
1885.017
|
|
Chi
squared
1587.008
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1885.0174
.42095
.41939
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1364.8984
.20030
.19813
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
76,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TMCOST
­.
4139121181
.55040263E­
01
­
7.520
.0000
LAND
­.
4413083339E­
02
.24256586E­
01
­.
182
.8556
PARK
.2889238455
.20255100
1.426
.1537
BEACH
1.207368209
.17687346
6.826
.0000
SIZE
­.
1666300490
.43001631E­
01
­
3.875
.0001
TKNP
­
1.209941000
.15811966
­
7.652
.0000
W
1.000000000
........(
Fixed
Parameter)........
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.5689085793
.80220195E­
01
7.092
.0000
INLND
.2194541282
.32836691E­
01
6.683
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
Reset$
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
G...
.
LPJ
save
file
contained
3040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
108
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
3040
|
|
Iterations
completed
16
|
|
Log
likelihood
function
­
1145.000
|
|
Restricted
log
likelihood
­
1885.017
|
|
Chi
squared
1480.036
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1885.0174
.39258
.39093
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1375.1701
.16738
.16512
|
|
Response
data
are
given
as
ind.
choice.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
76,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TMCOST
­.
3961462233
.63636381E­
01
­
6.225
.0000
LAND
.4948973070E­
02
.21565464E­
01
.229
.8185
PARK
1.285318053
.20220484
6.357
.0000
109
BEACH
.2082434656
.17670474
1.178
.2386
SIZE
­.
4155753691
.47635597E­
01
­
8.724
.0000
TKNP
­.
5810419808
.12380632
­
4.693
.0000
W
1.000000000
........(
Fixed
Parameter)........
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
.7004684103
.92253792E­
01
7.593
.0000
INLND
.2515142681
.43244241E­
01
5.816
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
Reset$
­­>
­­>
LOAD
;
File="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
G...
.
LPJ
save
file
contained
3040
observations.
­­>
create
;
sq_
wgt
=
sqr(
wgt_
300m)
;
sqrwgt
=
sq_
wgt*
river
;
sqgwgt
=
sq_
wgt*
glake
;
gwght
=
2.209
;
rwght
=
5.337
;
trpcost1
=
0.29*
ds*
2
;
rsze
=
river*
rchsze
;
if
(
river=
0
&
glake=
0)
lake=
1;
(
else)
lake=
0
;
lsze
=
lake*
rchsze
;
if
(
unempl=
1
|
home_
mk=
1
|
retired=
1)
apply=
0;
(
else)
apply=
1
;
trpcost2
=
(
0.29*
ds*
2)
+
((
0.33*
wage*(
ds/
40))*
2*
apply)$
­­>
Nlogit
;
Lhs
=
visitdm
;
Choices
=
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20,
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20
;
Tree
=
Erie(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20),
InLnd(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
;
Model:
U(
gl1,
gl2,
gl3,
gl4,
gl5,
gl6,
gl7,
gl8,
gl9,
gl10,
gl11,
gl12,
gl13,
gl14,
gl15,
gl16,
gl17,
gl18,
gl19,
gl20)
=
TrCost[­
0.0443476976]*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
gwght
/
U(
l1,
l2,
l3,
l4,
l5,
l6,
l7,
l8,
l9,
l10,
l11,
l12,
l13,
l14,
l15,
l16,
l17,
l18,
l19,
l20)
=
TrCost*
trpcost
+
TmCost*
timcost
+
land*
ln_
lndac
+
park*
park
+
...
+
size*
rchsze
+
TKNp*
tkn
+
W[
1]*
rwght
;
Prob
=
est_
prob
;
Wts=
visits$
Normal
exit
from
iterations.
Exit
status=
0.
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
VISITDM
|
|
Weighting
variable
VISITS
|
|
Number
of
observations
3040
|
|
Iterations
completed
15
|
|
Log
likelihood
function
­
1122.052
|
|
Restricted
log
likelihood
­
1885.017
|
|
Chi
squared
1525.932
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
R2=
1­
LogL/
LogL*
Log­
L
fncn
R­
sqrd
RsqAdj
|
|
No
coefficients
­
1885.0174
.40475
.40314
|
|
Constants
only.
Must
be
computed
directly.
|
|
Use
NLOGIT
;...;
RHS=
ONE
$
|
|
At
start
values
­
1396.4010
.19647
.19429
|
|
Response
data
are
given
as
ind.
choice.
|
110
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
FIML:
Nested
Multinomial
Logit
Model
|
|
The
model
has
2
levels.
|
|
Nested
Logit
form:
IV
parms
=
tauj|
i,
l,
si|
l
|
|
and
fl.
No
normalizations
imposed
a
priori.
|
|
p(
alt=
k|
b=
j,
l=
i,
t=
l)=
exp[
bX_
k|
jil]/
Sum
|
|
p(
b=
j|
l=
i,
t=
l)=
exp[
aY_
j|
il+
tauj|
ilIVj|
il)]/
|
|
Sum.
p(
l=
i|
t=
l)=
exp[
cZ_
i|
l+
si|
lIVi|
l)]/
Sum
|
|
p(
t=
l)=
exp[
exp[
qW_
l+
flIVl]/
Sum...
|
|
Number
of
obs.=
76,
skipped
0
bad
obs.
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+
Attributes
in
the
Utility
Functions
(
beta)
TRCOST
­.
4434769760E­
01........(
Fixed
Parameter)........
TMCOST
­.
3237779974
.53460997E­
01
­
6.056
.0000
LAND
.1146693904
.24543906E­
01
4.672
.0000
PARK
.4268463070
.20569916
2.075
.0380
BEACH
.3152947453
.14138913
2.230
.0257
SIZE
­.
3068148044
.48688932E­
01
­
6.302
.0000
TKNP
­.
4444119355
.13442225
­
3.306
.0009
W
1.000000000
........(
Fixed
Parameter)........
IV
parameters,
tau(
j|
i,
l),
sigma(
i|
l),
phi(
l)
ERIE
1.081871924
.15164235
7.134
.0000
INLND
.3564332896
.69798499E­
01
5.107
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
Write
;
respnum,
visitdm,
est_
prob
;
File
=
"
c:\
projects\
rum3\
results\
revised
models
4­
02\
probability
estim...
­­>
­­>
Reset$
111
"
Random
Draw
Parameter
Analysis
for
Revised
Models.
xls"
This
spreadsheet
contains
the
parameter
estimates
for
each
recreation
activity
for
all
of
the
relevant
random
draws.
The
mean
values
of
the
estimated
parameters
are
calculated.
This
document
is
contained
in
DCN
37782.
112
Estimation
of
the
Participation
Models
of
Recreation
113
Generate
Data
Sets
of
Participants
and
Non­
participants
114
"
Fishing
IV
Calculation.
sas"
This
program
pulls
together
demographic
information
for
fishing
participants.
The
inclusive
value
of
all
recreation
sites
is
calculated
based
on
the
mean
parameter
estimates
from
the
five
fishing
site
choice
model
estimations.
A
data
set
of
demographic
information
and
the
inclusive
value
is
created.
115
libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
activity=
fisher;
%
let
finalSet=
fish_
trp;

/*
Site
attributes
and
water
quality
variables
*/

data
attr;
set
reach.
rch_
info;

/*
Get
index
for
distance
data
*/

dsta=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
dsta=
9999
then
put
'
bad
observation';

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
116
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

sqrwght
=
sqrt(
wgt_
300m);

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
dsta
river
glake
ramp
rchsze
tkn
awqc_
ex
sqrwght;
run;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
data
initial;
set
demogr.
fullset2;

if
&
activity
=
0
then
delete;

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
ds{*}
_
1­_
1954;

set
lori.
matrix4
point=
zipid;

ivsumgl=
0;
ivsumriv=
0;
ivsumlake=
0;

do
i=
1
to
1954;
set
attr
point=
i;

/*
Create
Cost
of
trip
variables
*/
/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/
if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds(
dsta)*
2
+
(
wage*(
ds(
dsta)/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds(
dsta)/
40)*
2;

dist
=
ds(
dsta);

if
glake=
1
and
dist
<=
250
then
do;

iv_
gl
=
exp((­
0.0443*
trpcost
­
1.4743*
timcost
+
0.8777*
ramp
+
0.9083*
rchsze
117
­
0.5845*
tkn
­
0.5730*
awqc_
ex
+
1.411)/
0.8112);
ivsumgl=
ivsumgl+
iv_
gl;
end;
if
river
=
1
and
dist
<=
120
then
do;

iv_
riv
=
exp((­
0.0443*
trpcost
­
1.4743*
timcost
+
0.8777*
ramp
+
0.1706*
rchsze
+
0.0678*
sqrwght
­
0.5845*
tkn
­
0.5730*
awqc_
ex
+
4.445)/
0.5910);
ivsumriv=
ivsumriv+
iv_
riv;
end;
if
river
=
0
and
glake
=
0
and
dist
<=
120
then
do;

iv_
lake
=
exp((­
0.0443*
trpcost
­
1.4743*
timcost
+
0.8777*
ramp
+
0.0497*
rchsze
+
2.128)/
0.4287);
ivsumlake=
ivsumlake+
iv_
lake;
end;
end;

sumgl
=
0.8112*
log(
ivsumgl);
sumriv
=
0.5910*
log(
ivsumriv);
sumlake
=
0.4287*
log(
ivsumlake);

ivbase=
log(
exp(
sumgl)
+
exp(
sumriv)
+
exp(
sumlake));
run;

proc
means
data=
initial;
var
ivbase;
quit;

data
rand.&
finalSet;
set
initial;

keep
respnum
ivbase
numvis
age
male
nohs
college
black
kids6
kid7_
15
own_
boat
retired
home_
mk;
run;
118
"
Boating
IV
Calculation.
sas"
This
program
pulls
together
demographic
information
for
boating
participants.
The
inclusive
value
of
all
recreation
sites
is
calculated
based
on
the
mean
parameter
estimates
from
the
five
boating
site
choice
model
estimations.
A
data
set
of
demographic
information
and
the
inclusive
value
is
created.
119
libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
activity=
boater;
%
let
finalSet=
boat_
trp;

/*
Site
attributes
and
water
quality
variables
*/

data
attr;
set
reach.
rch_
info;

/*
Get
index
for
distance
data
*/

dsta=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
dsta=
9999
then
put
'
bad
observation';

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
120
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

sqrwght
=
sqrt(
wgt_
300m);

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
dsta
river
glake
rchsze
tkn
awqc_
ex
sqrwght;
run;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
data
initial;
set
demogr.
fullset2;

if
&
activity
=
0
then
delete;

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
ds{*}
_
1­_
1954;

set
lori.
matrix4
point=
zipid;

ivsumgl=
0;
ivsumoth=
0;

do
i=
1
to
1954;
set
attr
point=
i;

/*
Create
Cost
of
trip
variables
*/
/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/
if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds(
dsta)*
2
+
(
wage*(
ds(
dsta)/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds(
dsta)/
40)*
2;

dist
=
ds(
dsta);

if
glake=
1
and
dist
<=
250
then
do;

iv_
gl
=
exp((­
0.0443*
trpcost
­
0.362*
timcost
+
0.502*
rchsze
121
­
0.13*
sqrwght
­
1.187*
tkn
­
0.172*
awqc_
ex
+
1.17)/
0.296);
ivsumgl=
ivsumgl+
iv_
gl;
end;
if
glake
=
0
and
dist
<=
120
then
do;

iv_
oth
=
exp((­
0.0443*
trpcost
­
0.362*
timcost
+
0.502*
rchsze
­
0.017*
sqrwght
­
1.187*
tkn
­
0.172*
awqc_
ex
+
3.183)/
0.088);
ivsumoth=
ivsumoth+
iv_
oth;
end;
end;

sumgl
=
0.296*
log(
ivsumgl);
sumoth
=
0.088*
log(
ivsumoth);

ivbase=
log(
exp(
sumgl)
+
exp(
sumoth));
run;

proc
means
data=
initial;
var
ivbase;
quit;

data
rand.&
finalSet;
set
initial;

if
ivbase=.
then
delete;

keep
respnum
ivbase
numvis
age
male
nohs
college
black
kids6
kid7_
15
own_
boat
retired
home_
mk;
run;
122
"
Viewing
IV
Calculation.
sas"
This
program
pulls
together
demographic
information
for
viewing
participants.
The
inclusive
value
of
all
recreation
sites
is
calculated
based
on
the
mean
parameter
estimates
from
the
five
viewing
site
choice
model
estimations.
A
data
set
of
demographic
information
and
the
inclusive
value
is
created.
123
libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
activity=
viewer;
%
let
finalSet=
view_
trp;

/*
Site
attributes
and
water
quality
variables
*/

data
attr;
set
reach.
rch_
info;

/*
Get
index
for
distance
data
*/

dsta=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
dsta=
9999
then
put
'
bad
observation';

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
124
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

sqrwght
=
sqrt(
wgt_
300m);

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

if
glake=
0
and
river=
0
then
lake=
1;
else
lake=
0;

keep
dsta
river
glake
lake
rchsze
ln_
lndac
park
tkn;
run;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
data
initial;
set
demogr.
fullset2;

if
&
activity
=
0
then
delete;

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
ds{*}
_
1­_
1954;

set
lori.
matrix4
point=
zipid;

ivsum=
0;

do
i=
1
to
1954;
set
attr
point=
i;

/*
Create
Cost
of
trip
variables
*/
/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/
if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds(
dsta)*
2
+
(
wage*(
ds(
dsta)/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds(
dsta)/
40)*
2;

dist
=
ds(
dsta);

if
dist
<=
120
then
do;
125
iv
=
exp(­
0.0443*
trpcost
­
0.719*
timcost
+
0.162*
ln_
lndac
+
0.787*
park
­
0.711*
tkn
+
0.665*
glake*
rchsze
­
0.261*
river*
rchsze
­
0.429*
lake*
rchsze);
ivsum=
ivsum+
iv;
end;
end;

ivbase=
log(
ivsum);
run;

proc
means
data=
initial;
var
ivbase;
quit;

data
rand.&
finalSet;
set
initial;

if
ivbase=.
then
delete;

keep
respnum
ivbase
numvis
age
male
nohs
college
black
kids6
kid7_
15
own_
boat
retired
home_
mk;
run;
126
"
Swimming
IV
Calculation.
sas"
This
program
pulls
together
demographic
information
for
swimming
participants.
The
inclusive
value
of
all
recreation
sites
is
calculated
based
on
the
mean
parameter
estimates
from
six
of
the
seven
swimming
site
choice
model
estimations.
A
data
set
of
demographic
information
and
the
inclusive
value
is
created.
127
libname
lori
'
c:\
projects\
rum3\
data\
distan~
1\';
/*
Distance
Matrix
*/
libname
library
'
c:\
projects\
rum3\
data\
lib\';
/*
Format
Codes
*/
libname
demogr
'
c:\
projects\
rum3\
data\
respon~
1\';
/*
Respondent
Data
*/
libname
reach
'
c:\
projects\
rum3\
data\
waterq~
1\';
/*
Reach
Attributes
Data
*/
libname
rand
'
c:\
projects\
rum3\
data\
random~
1\
Models
3_
17_
02\';
/*
Random
Data
Folder
*/

/*
Setup
some
macro
variables
*/
%
let
activity=
swimer;
%
let
finalSet=
swim_
trp;

/*
Site
attributes
and
water
quality
variables
*/

data
attr;
set
reach.
rch_
info;

/*
Get
index
for
distance
data
*/

dsta=
input(
put(
rf1id,
rch_
fmt.),
4.);
if
dsta=
9999
then
put
'
bad
observation';

if
tkn=
0
or
tkn=.
then
tkn=
0.719;

/*
For
rivers
and
great
lakes
use
log
of
reach
length,
for
lakes
calculate
the
log
of
the
lake's
circumference
*/

if
river=
1
or
glake=
1
then
do;
if
rch_
len
^=
0
then
rchsze=
log(
rch_
len);
else
rch_
len
=
0;
end;
else
do;
/*
small
lakes
*/
pi
=
3.141592654;
area
=
exp(
ln_
acre)*
0.0015625;
/*
convert
log
of
acres
to
square
miles
*/
rad
=
sqrt(
area/
pi);
circ
=
2*
rad*
pi;
rchsze=
log(
circ);
end;

/*
Fish
Abundance
Measure
*/
/*
Standardized
Fish300m
generated
for
all
sites
in
Ohio
*/

if
fish300m=.
then
do;
if
river=
1
then
fish300m
=
625.28;
if
glake=
1
then
fish300m
=
259.99;
if
river=
0
and
glake=
0
then
fish300m
=
314.22;
end;
fish100m
=
fish300m/
3;
fish1m
=
fish300m/
300;

/*
Fish
Abundance
Measure
*/
/*
fill
in
with
average
by
waterbody
type
*/

if
wght300m
=.
then
do;
128
if
river=
1
then
wght300m
=
6.519;
if
glake=
1
then
wght300m
=
5.021;
if
river=
0
and
glake=
0
then
wght300m
=
9.173;
end;

/*
Convert
wght300m
from
kg
to
lbs
using
1kg
=
2.20462
lbs
*/

wgt_
300m
=
wght300m*
2.20462;

sqrwght
=
sqrt(
wgt_
300m);

if
iwb2=.
then
do;
if
river=
1
then
iwb2=
7.75;
if
glake=
1
then
iwb2=
7.46;
if
river=
0
and
glake=
0
then
iwb2=
7.28;
end;

keep
dsta
river
glake
ln_
lndac
rchsze
park
beach
tkn;
run;

/*
Open
the
demographic
data
file
and
get
chosen
site
id#
*/
data
initial;
set
demogr.
fullset2;

if
&
activity
=
0
then
delete;

zipid=
input(
put(
home,
zip_
fmt.),
3.0);
if
zipid
=
999
then
put
'
ZIPID
MISMATCH!!!
Respnum
=
'
respnum;
if
zipid
=
999
then
delete;

array
ds{*}
_
1­_
1954;

set
lori.
matrix4
point=
zipid;

ivsumgl=
0;
ivsumoth=
0;

do
i=
1
to
1954;
set
attr
point=
i;

/*
Create
Cost
of
trip
variables
*/
/*
Trip
cost,
applies
opportunity
cost
only
to
those
who
would
have
worked
*/
if
unempl=
1
or
home_
mk=
1
or
retired=
1
then
apply=
0;
else
apply=
1;
trpcost
=
0.29*
ds(
dsta)*
2
+
(
wage*(
ds(
dsta)/
40))*
2*
apply;

/*
Time
cost
only
applies
if
income
not
lost
*/
if
apply=
1
then
timcost=
0;
else
timcost=
(
ds(
dsta)/
40)*
2;

dist
=
ds(
dsta);

if
glake=
1
and
dist
<=
250
then
do;

iv_
gl
=
exp((­
0.0443*
trpcost
­
0.436*
timcost
+
0.058*
ln_
lndac
­
0.273*
rchsze
129
+
0.753*
park
+
0.491*
beach
­
0.660*
tkn
+
2.209)/
0.73);
ivsumgl=
ivsumgl+
iv_
gl;
end;
if
glake
=
0
and
dist
<=
120
then
do;

iv_
oth
=
exp((­
0.0443*
trpcost
­
0.436*
timcost
+
0.058*
ln_
lndac
­
0.273*
rchsze
+
0.753*
park
+
0.491*
beach
­
0.660*
tkn
+
5.337)/
0.275);
ivsumoth=
ivsumoth+
iv_
oth;
end;
end;

sumgl
=
0.73*
log(
ivsumgl);
sumoth
=
0.275*
log(
ivsumoth);

ivbase=
log(
exp(
sumgl)
+
exp(
sumoth));
run;

proc
means
data=
initial;
var
ivbase;
quit;

data
rand.&
finalSet;
set
initial;

keep
respnum
ivbase
numvis
age
male
nohs
college
black
kids6
kid7_
15
own_
boat
retired
home_
mk;
run;
130
Estimate
the
Trip
Participation
Models
in
Limdep
131
"
Fishing
Trip
Model.
lim"
This
program
estimates
a
poisson
model
of
the
number
of
seasonal
fishing
trips
taken
based
on
the
calculated
inclusive
value
and
several
demographic
variables.
132
?
PROGRAM:
Fishing
Trip
Model.
lim
?
DATE:
4/
24/
2002
?
AUTHOR:
Stuart
Smith
?
This
is
an
alternative
trip
frequency
model
?
Estimate
the
nested
logit
model
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$

create
;
if
(
numvis
>
90)
numvis2
=
5;
(
else)
numvis2=
numvis
;
if
(
numvis
>
90)
numvis3
=
50;
(
else)
numvis3=
numvis
;
if
(
numvis
>
90)
numvis4
=
100;
(
else)
numvis4=
numvis
;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$

negbin
;
Lhs=
numvis2
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

calc
;
list
;
trp=
sum(
numvis2)
;
tot=
sum(
MUI)$

create
;
z
=
((
numvis2
­
MUI)^
2
­
numvis2)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
Regress;
Lhs
=
z;
Rhs
=
wi1$
Regress;
Lhs
=
z;
Rhs
=
wi2$

?
open;
output=
c:\
projects\
rum3\
data\
parame~
1\
pois_
f.
out$
?
write;
b$
?
close$
133
Program
Output
134
­­>
RESET
­­>
RESET
­­>
LOAD;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
Trip...
.
LPJ
save
file
contained
86
observations.
­­>
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$
­­>
create
;
if
(
numvis
>
90)
numvis2
=
5;
(
else)
numvis2=
numvis
;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$
­­>
negbin
;
Lhs=
numvis2
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Poisson
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS2
|
|
Weighting
variable
None
|
|
Number
of
observations
86
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
531.8702
|
|
Restricted
log
likelihood
­
592.8847
|
|
Chi
squared
122.0289
|
|
Degrees
of
freedom
7
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
Chi­
squared
=
1765.31599
RsqP=
­.
3210
|
|
G
­
squared
=
798.67217
RsqD=
.0842
|
|
Overdispersion
tests:
g=
mu(
i)
:
1.613
|
|
Overdispersion
tests:
g=
mu(
i)^
2:
.748
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.4040950857
.21988308E­
01
18.378
.0000
5.8935620
AGE
­.
9991652696E­
02
.26451186E­
02
­
3.777
.0002
39.701163
MALE
.6328468447
.88014248E­
01
7.190
.0000
.66279070
NOHS
.4026070320
.94103691E­
01
4.278
.0000
.11627907
COLLEGE
­.
4464870211
.10375627
­
4.303
.0000
.20930233
BLACK
.7021564208
.11932364
5.884
.0000
.69767442E­
01
YNGKIDS
­.
3944586161
.91407929E­
01
­
4.315
.0000
.26744186
OLDKIDS
­.
4285815857
.74914517E­
01
­
5.721
.0000
.43023256
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Negative
Binomial
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS2
|
|
Weighting
variable
None
|
|
Number
of
observations
86
|
|
Iterations
completed
14
|
|
Log
likelihood
function
­
290.0122
|
|
Restricted
log
likelihood
­
531.8702
|
|
Chi
squared
483.7160
|
|
Degrees
of
freedom
1
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.2812574788
.53272599E­
01
5.280
.0000
5.8935620
AGE
.8506167209E­
02
.79742048E­
02
1.067
.2861
39.701163
MALE
.4929836321
.23888569
2.064
.0390
.66279070
NOHS
.2606409855
.39706836
.656
.5116
.11627907
COLLEGE
­.
4825189731E­
01
.31104037
­.
155
.8767
.20930233
BLACK
.6667314107E­
01
.51529272
.129
.8970
.69767442E­
01
YNGKIDS
.1596296845
.24367576
.655
.5124
.26744186
135
OLDKIDS
­.
3633889665
.22982040
­
1.581
.1138
.43023256
Dispersion
parameter
for
count
data
model
Alpha
.8817610919
.14255255
6.186
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
calc
;
list
;
trp=
sum(
numvis2)
;
tot=
sum(
MUI)$
TRP
=
.85600000000000000D+
03
TOT
=
.86745235150844050D+
03
Calculator:
Computed
2
scalar
results
­­>
create
;
z
=
((
numvis2
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
­­>
Regress;
Lhs
=
z;
Rhs
=
wi1$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
8.680193074
,
S.
D.=
27.31867369
|
|
Model
size:
Observations
=
86,
Parameters
=
1,
Deg.
Fr.=
85
|
|
Residuals:
Sum
of
squares=
63436.34426
,
Std.
Dev.=
27.31867
|
|
Fit:
R­
squared=
.000000,
Adjusted
R­
squared
=
.00000
|
|
Diagnostic:
Log­
L
=
­
405.9768,
Restricted(
b=
0)
Log­
L
=
­
405.9768
|
|
LogAmemiyaPrCrt.=
6.627,
Akaike
Info.
Crt.=
9.465
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
2.11626,
Rho
=
­.
05813
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI1
12.27564677
4.1660587
2.947
.0041
.70710678
­­>
Regress;
Lhs
=
z;
Rhs
=
wi2$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
8.680193074
,
S.
D.=
27.31867369
|
|
Model
size:
Observations
=
86,
Parameters
=
1,
Deg.
Fr.=
85
|
|
Residuals:
Sum
of
squares=
63520.55394
,
Std.
Dev.=
27.33680
|
|
Fit:
R­
squared=
­.
001327,
Adjusted
R­
squared
=
­.
00133
|
|
Diagnostic:
Log­
L
=
­
406.0339,
Restricted(
b=
0)
Log­
L
=
­
405.9768
|
|
LogAmemiyaPrCrt.=
6.628,
Akaike
Info.
Crt.=
9.466
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
2.10735,
Rho
=
­.
05367
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI2
1.129002746
.38592648
2.925
.0044
7.1323423
­­>
SAVE;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Fishing
Trip...
136
"
Boating
Trip
Model.
lim"
This
program
estimates
a
poisson
model
of
the
number
of
seasonal
boating
trips
taken
based
on
the
calculated
inclusive
value
and
several
demographic
variables.
137
?
PROGRAM:
Boating
Trip
Model.
lim
?
DATE:
4/
24/
2002
?
AUTHOR:
Stuart
Smith
?
This
is
an
alternative
trip
frequency
model
?
Estimate
the
nested
logit
model
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$

create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$

negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids,
own_
boat
;
keep
=
MUI$

calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$

create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
Regress;
Lhs
=
z;
Rhs
=
wi1$
Regress;
Lhs
=
z;
Rhs
=
wi2$

?
open;
output=
c:\
projects\
rum3\
data\
parame~
1\
pois_
f.
out$
?
write;
b$
?
close$
138
Program
Output
139
­­>
RESET
­­>
READ;
NOBS=
80
;
NVAR=
13
;
NAMES=
RESPNUM,
AGE,
RETIRED,
HOME_
MK,
KIDS6,
KID7_
15,
MALE,
NOHS,
COLLEGE,
BLACK,
OWN_
BOAT,
NUMVIS,
IVBASE
$
­­>
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$
­­>
create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$
­­>
negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids,
own_
boat
;
keep
=
MUI$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Poisson
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
80
|
|
Iterations
completed
6
|
|
Log
likelihood
function
­
305.3130
|
|
Restricted
log
likelihood
­
415.1901
|
|
Chi
squared
219.7543
|
|
Degrees
of
freedom
8
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
Chi­
squared
=
467.95601
RsqP=
.4286
|
|
G
­
squared
=
355.99466
RsqD=
.3886
|
|
Overdispersion
tests:
g=
mu(
i)
:
2.945
|
|
Overdispersion
tests:
g=
mu(
i)^
2:
2.964
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
­.
4440876358E­
02
.67109195E­
01
­.
066
.9472
3.6750170
AGE
.1662219738E­
01
.41738058E­
02
3.983
.0001
39.616250
MALE
.7509844794
.10024936
7.491
.0000
.46250000
NOHS
­.
8612317842
.33111838
­
2.601
.0093
.87500000E­
01
COLLEGE
.2664900777
.10843191
2.458
.0140
.33750000
BLACK
1.570470754
.43202314
3.635
.0003
.12500000E­
01
YNGKIDS
­.
1702674777E­
01
.15618491
­.
109
.9132
.21250000
OLDKIDS
.5410092783
.10064750
5.375
.0000
.35000000
OWN_
BOAT
.6535613480
.11639229
5.615
.0000
.56250000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Negative
Binomial
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
80
|
|
Iterations
completed
14
|
|
Log
likelihood
function
­
211.2896
|
|
Restricted
log
likelihood
­
305.3130
|
|
Chi
squared
188.0467
|
|
Degrees
of
freedom
1
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.1133109108
.12273412
.923
.3559
3.6750170
AGE
.8445200055E­
02
.88532122E­
02
.954
.3401
39.616250
MALE
.7177059652
.21427934
3.349
.0008
.46250000
NOHS
­
1.052230067
.52811227
­
1.992
.0463
.87500000E­
01
COLLEGE
.9346683510E­
01
.23010798
.406
.6846
.33750000
BLACK
1.611279146
.95767474
1.682
.0925
.12500000E­
01
YNGKIDS
­.
1394734456
.29717937
­.
469
.6388
.21250000
140
OLDKIDS
.4594353402
.22034560
2.085
.0371
.35000000
OWN_
BOAT
.7209255677
.21985949
3.279
.0010
.56250000
Dispersion
parameter
for
count
data
model
Alpha
.5779682692
.13765158
4.199
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$
TRP
=
.48500000000000000D+
03
TOT
=
.48062846504042140D+
03
Calculator:
Computed
2
scalar
results
­­>
create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
­­>
Regress;
Lhs
=
z;
Rhs
=
wi1$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
3.345917408
,
S.
D.=
8.726172205
|
|
Model
size:
Observations
=
80,
Parameters
=
1,
Deg.
Fr.=
79
|
|
Residuals:
Sum
of
squares=
6015.540426
,
Std.
Dev.=
8.72617
|
|
Fit:
R­
squared=
.000000,
Adjusted
R­
squared
=
.00000
|
|
Diagnostic:
Log­
L
=
­
286.3181,
Restricted(
b=
0)
Log­
L
=
­
286.3181
|
|
LogAmemiyaPrCrt.=
4.345,
Akaike
Info.
Crt.=
7.183
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
1.98550,
Rho
=
.00725
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI1
4.731841777
1.3797290
3.430
.0010
.70710678
­­>
Regress;
Lhs
=
z;
Rhs
=
wi2$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
3.345917408
,
S.
D.=
8.726172205
|
|
Model
size:
Observations
=
80,
Parameters
=
1,
Deg.
Fr.=
79
|
|
Residuals:
Sum
of
squares=
5769.266819
,
Std.
Dev.=
8.54568
|
|
Fit:
R­
squared=
.040940,
Adjusted
R­
squared
=
.04094
|
|
Model
test:
F[
1,
79]
=
3.37,
Prob
value
=
.07006
|
|
Diagnostic:
Log­
L
=
­
284.6460,
Restricted(
b=
0)
Log­
L
=
­
286.3181
|
|
LogAmemiyaPrCrt.=
4.303,
Akaike
Info.
Crt.=
7.141
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
2.06756,
Rho
=
­.
03378
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI2
.7465778060
.18880363
3.954
.0002
4.2481956
­­>
SAVE;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Boating
Trip...
141
"
Viewing
Trip
Model.
lim"
This
program
estimates
a
poisson
model
of
the
number
of
seasonal
viewing
trips
taken
based
on
the
calculated
inclusive
value
and
several
demographic
variables.
142
?
PROGRAM:
Viewing
Trip
Model.
lim
?
DATE:
4/
24/
2002
?
AUTHOR:
Stuart
Smith
?
This
is
an
alternative
trip
frequency
model
?
Estimate
the
nested
logit
model
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$

create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$

negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$

create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
Regress;
Lhs
=
z;
Rhs
=
wi1$
Regress;
Lhs
=
z;
Rhs
=
wi2$

?
open;
output=
c:\
projects\
rum3\
data\
parame~
1\
pois_
f.
out$
?
write;
b$
?
close$
143
Program
Output
144
­­>
RESET
­­>
READ;
NOBS=
87
;
NVAR=
13
;
NAMES=
RESPNUM,
AGE,
RETIRED,
HOME_
MK,
KIDS6,
KID7_
15,
MALE,
NOHS,
COLLEGE,
BLACK,
OWN_
BOAT,
NUMVIS,
IVBASE
$
­­>
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$
­­>
create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$
­­>
negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Poisson
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
87
|
|
Iterations
completed
8
|
|
Log
likelihood
function
­
913.8584
|
|
Chi­
squared
=
5949.59105
RsqP=
­
1.0987
|
|
G
­
squared
=
1750.02090
RsqD=
­.
1898
|
|
Overdispersion
tests:
g=
mu(
i)
:
1.844
|
|
Overdispersion
tests:
g=
mu(
i)^
2:
.767
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.3463350680
.28446691E­
01
12.175
.0000
2.7652279
AGE
.7229099258E­
02
.24662540E­
02
2.931
.0034
37.141379
MALE
.8096972691
.76008327E­
01
10.653
.0000
.49425287
NOHS
1.336927754
.10678016
12.520
.0000
.12643678
COLLEGE
.7985514469
.88412995E­
01
9.032
.0000
.33333333
BLACK
­
1.740269464
.20094152
­
8.661
.0000
.11494253
YNGKIDS
.1309367883E­
02
.88296734E­
01
.015
.9882
.27586207
OLDKIDS
­.
5146558617
.99210166E­
01
­
5.188
.0000
.26436782
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Negative
Binomial
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
87
|
|
Iterations
completed
15
|
|
Log
likelihood
function
­
292.8573
|
|
Restricted
log
likelihood
­
913.8584
|
|
Chi
squared
1242.002
|
|
Degrees
of
freedom
1
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.7150852940E­
01
.48468233E­
01
1.475
.1401
2.7652279
AGE
.4419291427E­
01
.77786156E­
02
5.681
.0000
37.141379
MALE
.6893951195
.27135985
2.541
.0111
.49425287
NOHS
1.237551241
.45803367
2.702
.0069
.12643678
COLLEGE
.2674894902
.36352662
.736
.4618
.33333333
BLACK
­
1.596079530
.52335440
­
3.050
.0023
.11494253
YNGKIDS
­.
2310962015
.34983236
­.
661
.5089
.27586207
OLDKIDS
­.
2359310859
.36040645
­.
655
.5127
.26436782
Dispersion
parameter
for
count
data
model
Alpha
1.678601334
.23468961
7.152
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)
145
­­>
calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$
TRP
=
.80300000000000000D+
03
TOT
=
.10020967902256440D+
04
Calculator:
Computed
2
scalar
results
­­>
create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
­­>
Regress;
Lhs
=
z;
Rhs
=
wi1$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
23.25176030
,
S.
D.=
69.65802634
|
|
Model
size:
Observations
=
87,
Parameters
=
1,
Deg.
Fr.=
86
|
|
Residuals:
Sum
of
squares=
417292.6945
,
Std.
Dev.=
69.65803
|
|
Fit:
R­
squared=
.000000,
Adjusted
R­
squared
=
.00000
|
|
Diagnostic:
Log­
L
=
­
492.1378,
Restricted(
b=
0)
Log­
L
=
­
492.1378
|
|
LogAmemiyaPrCrt.=
8.499,
Akaike
Info.
Crt.=
11.337
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
2.07430,
Rho
=
­.
03715
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI1
32.88295476
10.561523
3.113
.0025
.70710678
­­>
Regress;
Lhs
=
z;
Rhs
=
wi2$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
23.25176030
,
S.
D.=
69.65802634
|
|
Model
size:
Observations
=
87,
Parameters
=
1,
Deg.
Fr.=
86
|
|
Residuals:
Sum
of
squares=
434241.0863
,
Std.
Dev.=
71.05853
|
|
Fit:
R­
squared=
­.
040615,
Adjusted
R­
squared
=
­.
04062
|
|
Diagnostic:
Log­
L
=
­
493.8696,
Restricted(
b=
0)
Log­
L
=
­
492.1378
|
|
LogAmemiyaPrCrt.=
8.538,
Akaike
Info.
Crt.=
11.376
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
2.05216,
Rho
=
­.
02608
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI2
1.747824303
.71601108
2.441
.0167
8.1447062
­­>
SAVE;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Viewing
Trip...
146
"
Swimming
Trip
Model.
lim"
This
program
estimates
a
poisson
model
of
the
number
of
seasonal
swimming
trips
taken
based
on
the
calculated
inclusive
value
and
several
demographic
variables.
147
?
PROGRAM:
Swimming
Trip
Model.
lim
?
DATE:
4/
24/
2002
?
AUTHOR:
Stuart
Smith
?
This
is
an
alternative
trip
frequency
model
?
Estimate
the
nested
logit
model
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$

create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$

negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$

create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
Regress;
Lhs
=
z;
Rhs
=
wi1$
Regress;
Lhs
=
z;
Rhs
=
wi2$

?
open;
output=
c:\
projects\
rum3\
data\
parame~
1\
pois_
f.
out$
?
write;
b$
?
close$
148
Program
Output
149
­­>
RESET
­­>
READ;
NOBS=
89
;
NVAR=
13
;
NAMES=
RESPNUM,
AGE,
RETIRED,
HOME_
MK,
KIDS6,
KID7_
15,
MALE,
NOHS,
COLLEGE,
BLACK,
OWN_
BOAT,
NUMVIS,
IVBASE
$
­­>
Title;
FIML
ESTIMATES
OF
POISSON
TRIP
MODEL$
­­>
create;
if
(
kids6
>
0)
yngkids
=
1;(
else)
yngkids=
0
;
if
(
kid7_
15
>
0)
oldkids=
1;(
else)
oldkids=
0$
­­>
negbin
;
Lhs=
numvis
;
Rhs=
ivbase,
age,
male,
nohs,
college,
black,
yngkids,
oldkids
;
keep
=
MUI$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Poisson
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
89
|
|
Iterations
completed
7
|
|
Log
likelihood
function
­
671.2538
|
|
Restricted
log
likelihood
­
711.1410
|
|
Chi
squared
79.77437
|
|
Degrees
of
freedom
7
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
|
Chi­
squared
=
1492.05592
RsqP=
.1160
|
|
G
­
squared
=
1067.11402
RsqD=
.0499
|
|
Overdispersion
tests:
g=
mu(
i)
:
3.754
|
|
Overdispersion
tests:
g=
mu(
i)^
2:
3.851
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.4361449616
.28358342E­
01
15.380
.0000
5.0138383
AGE
­.
7648249050E­
02
.33407344E­
02
­
2.289
.0221
35.213483
MALE
.3517089400
.72857263E­
01
4.827
.0000
.47191011
NOHS
.3570364738
.11902117
3.000
.0027
.13483146
COLLEGE
.3375014787E­
01
.85448571E­
01
.395
.6929
.30337079
BLACK
­
1.008593414
.59121123
­
1.706
.0880
.22471910E­
01
YNGKIDS
­.
5461693024
.11175651
­
4.887
.0000
.23595506
OLDKIDS
.1549628640
.71420693E­
01
2.170
.0300
.44943820
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

Normal
exit
from
iterations.
Exit
status=
0.

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Negative
Binomial
Regression
|
|
Maximum
Likelihood
Estimates
|
|
Dependent
variable
NUMVIS
|
|
Weighting
variable
None
|
|
Number
of
observations
89
|
|
Iterations
completed
14
|
|
Log
likelihood
function
­
282.2638
|
|
Restricted
log
likelihood
­
671.2538
|
|
Chi
squared
777.9801
|
|
Degrees
of
freedom
1
|
|
Prob[
ChiSqd
>
value]
=
.0000000
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
b/
St.
Er.|
P[|
Z|>
z]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
IVBASE
.3692122095
.94793639E­
01
3.895
.0001
5.0138383
AGE
­.
2481943673E­
03
.10596582E­
01
­.
023
.9813
35.213483
MALE
.5380657729
.24090484
2.234
.0255
.47191011
NOHS
.6274846207
.47499545
1.321
.1865
.13483146
COLLEGE
.1010097360
.27869909
.362
.7170
.30337079
BLACK
­.
9031245406
1.0765324
­.
839
.4015
.22471910E­
01
YNGKIDS
­.
5531118826
.32065987
­
1.725
.0845
.23595506
OLDKIDS
.5870898654E­
01
.25001043
.235
.8143
.44943820
150
Dispersion
parameter
for
count
data
model
Alpha
1.055849552
.16018556
6.591
.0000
(
Note:
E+
nn
or
E­
nn
means
multiply
by
10
to
+
or
­
nn
power.)

­­>
calc
;
list
;
trp=
sum(
numvis)
;
tot=
sum(
MUI)$
TRP
=
.78400000000000000D+
03
TOT
=
.80740926483060120D+
03
Calculator:
Computed
2
scalar
results
­­>
create
;
z
=
((
numvis
­
MUI)^
2
­
numvis)
/
(
Sqr(
2)*
MUI)
;
wi1
=
MUI
/
(
Sqr(
2)*
MUI)
;
wi2
=
MUI^
2
/
(
Sqr(
2)*
MUI)$
­­>
Regress;
Lhs
=
z;
Rhs
=
wi1$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
10.77074625
,
S.
D.=
26.15529684
|
|
Model
size:
Observations
=
89,
Parameters
=
1,
Deg.
Fr.=
88
|
|
Residuals:
Sum
of
squares=
60200.76063
,
Std.
Dev.=
26.15530
|
|
Fit:
R­
squared=
.000000,
Adjusted
R­
squared
=
.00000
|
|
Diagnostic:
Log­
L
=
­
416.2833,
Restricted(
b=
0)
Log­
L
=
­
416.2833
|
|
LogAmemiyaPrCrt.=
6.539,
Akaike
Info.
Crt.=
9.377
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
1.80114,
Rho
=
.09943
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI1
15.23213542
3.9208448
3.885
.0002
.70710678
­­>
Regress;
Lhs
=
z;
Rhs
=
wi2$

+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
|
Ordinary
least
squares
regression
Weighting
variable
=
none
|
|
Dep.
var.
=
Z
Mean=
10.77074625
,
S.
D.=
26.15529684
|
|
Model
size:
Observations
=
89,
Parameters
=
1,
Deg.
Fr.=
88
|
|
Residuals:
Sum
of
squares=
59584.77814
,
Std.
Dev.=
26.02114
|
|
Fit:
R­
squared=
.010232,
Adjusted
R­
squared
=
.01023
|
|
Model
test:
F[
1,
88]
=
.91,
Prob
value
=
.34280
|
|
Diagnostic:
Log­
L
=
­
415.8256,
Restricted(
b=
0)
Log­
L
=
­
416.2833
|
|
LogAmemiyaPrCrt.=
6.529,
Akaike
Info.
Crt.=
9.367
|
|
Model
does
not
contain
ONE.
R­
squared
and
F
can
be
negative!
|
|
Autocorrel:
Durbin­
Watson
Statistic
=
1.69318,
Rho
=
.15341
|
+­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­+
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
|
Variable
|
Coefficient
|
Standard
Error
|
t­
ratio
|
P[|
T|>
t]
|
Mean
of
X|
+­­­­­­­­­+­­­­­­­­­­­­­­+­­­­­­­­­­­­­­­­+­­­­­­­­+­­­­­­­­­+­­­­­­­­­­+
WI2
1.557485611
.38745940
4.020
.0001
6.4148828
­­>
SAVE;
file="
C:\
Projects\
Rum3\
Data\
Random
Draws\
Models
3_
17_
02\
Swimming
Tri...
