Bristol Bay 2019 District Harvest

Definition of strata for mixed stock analysis

This documents the definition of strata (time and area periods aka mixtures) for mixed stock analysis. Our budget provides for 15 strata. We have traditionally allocated these as follows:

* 3 in Ugashik

* 3 in Egegik

* 4 in Naknek-Kvichak (3 for drift/non-Kvichak Set harvests, 1 for Kvichak Section Set)

* 4 in Nushagak (3 for drift/non-Igushik Set harvests, 1 for Igushik Section Set)

* 1 in Togiak

We have mixed it up in recent years to better characterize harvests of some subdistricts or of very large harvests (Naknek Section Set, NRSHA, 4 strata for large harvests in Nushagak District in 2018, etc.), so this document will look at 2019 harvests among districts and traditionally analyzed subdistricts and dates to help GCL/area staff settle on an experimental design.

I tapped the Mariner database on August 14th and made a query for preliminary harvests by date in long form. It’s saved as “Mariner harvests for MSA strata definition long form” in the “/shared/Commercial Fisheries/Region II/Salmon/User Reports/Bristol Bay” directory of OceanAK.

Load functions and set up working environment

Read in harvest data and get into shape

Preliminary harvests among districts by date and subdistrict

Preliminary harvests among districts by date and subdistrict from June 20 - July 20 (note y-axis varies)

District-specific preliminary harvests by date and subdistrict

Summary of harvests across districts and proportional allocation of 15 strata among districts

What proportion of the total Bay-wide harvest did each district catch?

How would we allocate our 15 strata if we split them out proportional to catch?

Break out areas traditionally analyzed separately: Kvichak Section Set, Igushik Section, Naknek Section Set, NRSHA, WRSHA

We probably want to analyze some subdistricts separately from the district they are in because stock compositions of those areas have traditionally differed from their district as a whole.

For example, special harvest areas tend to have very ‘clean’ stock compositions compared to more mixed district-wide harvests, Kvichak and Igushik Set are more heavily weighted towards their local stock than the drift catches in their respective districts, etc.

Here is the same summary of what proportional allocation of strata would look like including these traditionally analyzed areas.

For run reconstruction this year and design of MSA strata in 2019, I propose we:

* Assume 100% Naknek in NRSHA

* Assume 100% Wood in WRSHA

* Apply the average of all available years estimates for Igushik Section

* Allocate just 1 stratum for each of: Ugashik, Togiak, Kvichak Section Set, and Naknek Section Set

* Allocate 3 strata/time periods for Naknek-Kvichak Drift

* Allocate 4 strata/time periods for both Nushagak and Egegik

That would result in:

Calculation of Harvest/Stratum with proposed experimental design

Calculation of number of samples to analyze by date from each district given proposed design

Ugashik - single stratum

## [1] 193
## [1] 190

Egegik - Four temporal strata

## [1] 192
## [1] 190
## [1] 189
## [1] 190
## [1] 191
## [1] 190

Naknek-Kvichak - Three temporal strata for drift + Kvichak Section Set + Naknek Section Set

## [1] NS 00 KS 25
## 21 Levels: 00 10 11 20 21 25 30 31 32 33 34 35 41 70 71 72 ES KS NS ... XX
## [1] 190
## [1] 191
## [1] 190
## [1] 189
## [1] 190
## [1] 187
## [1] 190
## [1] 187
## [1] 190

Nushagak - Four temporal strata excluding Igushik Section and WRSHA

## [1] 11 00 31 32 33 34 35 41
## 21 Levels: 00 10 11 20 21 25 30 31 32 33 34 35 41 70 71 72 ES KS NS ... XX
## [1] 190
## [1] 190
## [1] 190
## [1] 189
## [1] 190

Togiak - single stratum

## [1] 186
## [1] 190

2019 ASL

Connect to FDMS and read in data…

# Create connection driver and open connection
jdbcDriver <- JDBC(driverClass="oracle.jdbc.OracleDriver", 
                   classPath="C:/Users/gbbuck/Downloads/ojdbc8.jar")



#jdbcConnection.mariner <- dbConnect(jdbcDriver, 
#                            "jdbc:oracle:thin:@//10.209.2.34:1521/dfgmarinerp.us1.ocm.s7134325.oraclecloudatcustomer.com", 
#                            "mariner", "reniraM2012")

jdbcConnection.fdms <- dbConnect(jdbcDriver, 
                            "jdbc:oracle:thin:@//10.209.2.34:1521/dfgmarinerp.us1.ocm.s7134325.oraclecloudatcustomer.com", 
                            "fdms", "fdmspass")

dat.fdms <- dbGetQuery(jdbcConnection.fdms,"SELECT 
                                      fish.FISHID,
                                      fish.SAMPLINGSESSIONID,
                                      fish.AGEERRORID,
                                      fish.SPECIESID,
                                      fish.SEXID,
                                      fish.FISHLENGTH,
                                      fish.FISHWEIGHT,
                                      fish.FRESHAGE,
                                      fish.SEAAGE,
                                      SamplingSession.SAMPLERID,
                                      SamplingSession.CATCHDATE,
                                      SamplingSession.SAMPLEDATE,
                                      SamplingSession.GEARID,
                                      SamplingLocation.SAMPLINGLOCATIONID,
                                      SamplingLocation.SAMPLINGCODENAME,
                                      SamplingLocation.LOCATIONID,
                                      SamplingLocation.PROJECTID,
                                      SamplingLocation.STATAREAID,
                                      SamplingLocation.AREAID,
                                      SamplingLocation.MARINER_CODE,
                                      Stream.STREAMCODE,
                                      Subdistrict.SUBDISTRICTCODE,
                                      Location.LOCATIONCODE,
                                      District.DISTRICTNAME,
                                      District.DISTRICTCODE
                                      FROM fish
                                      LEFT JOIN SamplingSession ON fish.SAMPLINGSESSIONID = SamplingSession.SAMPLINGSESSIONID
                                      LEFT JOIN SamplingLocation ON SamplingSession.SAMPLINGLOCATIONID = SamplingLocation.SAMPLINGLOCATIONID
                                      JOIN Location ON SamplingLocation.LocationId = Location.LocationId
                                      JOIN Stream ON Location.StreamId = Stream.StreamId
                                      JOIN SubDistrict ON Stream.SubDistrictId = SubDistrict.SubDistrictId
                                      JOIN District ON SubDistrict.DistrictId = District.DistrictId")

dat.fdms <- dat.fdms %>%
  mutate(CATCHDATE = as.Date(CATCHDATE)) %>%
  mutate(year = year(CATCHDATE)) %>%
  mutate(month = month(CATCHDATE)) %>%
  mutate(day = day(CATCHDATE)) %>%
  mutate(plot.year = year(Sys.Date())) %>%
  mutate(plot.date = make_datetime(plot.year,month,day)) %>%
  mutate(stat.code = paste(DISTRICTCODE,SUBDISTRICTCODE,STREAMCODE,LOCATIONCODE,sep = "-")) %>%
  mutate(stat.code.short = paste(DISTRICTCODE,SUBDISTRICTCODE,"samples",sep = "-")) %>%
  mutate(DISTRICTCODE = as.numeric(DISTRICTCODE)) %>%
  mutate(STREAMCODE = as.numeric(STREAMCODE)) %>%
  mutate(AGE = paste(FRESHAGE,SEAAGE,sep = ".")) %>%
  filter(year == 2019)

Ugashik ASL Summary

t <- dat.fdms %>%
  filter(DISTRICTCODE == 321)

tbl <- table(t$plot.date,t$SAMPLINGCODENAME)
kable(tbl)
Ugashik Drift Ugashik River Escapement
2019-06-26 169 0
2019-06-30 240 0
2019-07-02 185 0
2019-07-05 210 0
2019-07-08 240 0
2019-07-09 0 155
2019-07-10 0 14
2019-07-11 0 12
2019-07-14 0 12
2019-07-17 0 114
2019-07-18 0 174
2019-07-19 240 130
2019-07-20 184 240
2019-07-21 240 144
2019-07-22 237 96
2019-07-23 0 144
2019-07-24 0 96
2019-07-25 0 144

Ugashik harvest ASL samples

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Ugashik Drift") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)

Ugashik Escapement ASL samples

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Ugashik River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)

Egegik ASL Summary

t <- dat.fdms %>%
  filter(DISTRICTCODE == 322)

tbl <- table(t$plot.date,t$SAMPLINGCODENAME)
kable(tbl)
Egegik Drift Egegik River (SHA) Egegik River Escapement
2019-06-19 240 0 0
2019-06-21 240 0 48
2019-06-23 137 0 0
2019-06-24 240 0 95
2019-06-25 240 0 141
2019-06-26 240 0 143
2019-06-27 240 0 0
2019-06-28 230 0 0
2019-06-29 240 0 0
2019-06-30 240 0 140
2019-07-01 216 0 0
2019-07-02 240 0 0
2019-07-03 240 0 96
2019-07-04 229 0 144
2019-07-05 240 0 0
2019-07-06 231 0 144
2019-07-07 240 0 96
2019-07-08 240 0 0
2019-07-09 240 0 144
2019-07-10 240 0 144
2019-07-11 240 0 0
2019-07-12 240 0 0
2019-07-13 450 0 240
2019-07-15 240 0 96
2019-07-16 236 0 0
2019-07-17 240 0 0
2019-07-18 0 240 84

Egegik Drift

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Egegik Drift") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),3),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.744
1.3 0.168
2.2 0.065
2.3 0.023

Egegik River SHA

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Egegik River (SHA)") 

kable(round(table(t$AGE)/nrow(t),3),col.names = c("Age","Proportion"))
Age Proportion
. 0.079
1.2 0.746
1.3 0.096
2.1 0.004
2.2 0.067
2.3 0.008

Egegik Escapement

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Egegik River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.88
1.3 0.03
2.2 0.09
2.3 0.01

Naknek-Kvichak ASL Summary

t <- dat.fdms %>%
  filter(DISTRICTCODE == 324)

tbl <- table(t$plot.date,t$SAMPLINGCODENAME)
kable(tbl)
Alagnak River Escapement Kvichak River Escapement Kvichak Section-Set Kvichak Section Set - Graveyard to Libbyville Kvichak Section Set - NW marker to Copenhagen Cr. Naknek-Kvichak District Drift Naknek River Escapement Naknek Section Drift Naknek Section Set - Pederson Pt. To N Naknek Pt. Naknek Section Set - S. Naknek Pt. To Johnson Hill Naknek SHA Drift
2019-06-24 0 0 0 0 0 0 0 240 0 0 0
2019-06-25 0 0 0 0 161 204 0 0 240 0 0
2019-06-26 0 0 0 0 0 216 0 0 0 0 0
2019-06-27 0 0 0 0 0 240 130 0 0 0 0
2019-06-28 0 0 0 0 0 0 144 0 0 0 0
2019-06-29 0 0 0 240 0 0 83 211 240 0 0
2019-06-30 0 0 0 0 0 233 46 0 0 0 0
2019-07-01 0 0 0 0 0 187 144 0 240 0 0
2019-07-02 0 0 240 0 0 240 0 0 0 0 0
2019-07-03 0 0 0 0 0 0 96 240 0 0 0
2019-07-04 0 0 0 0 0 0 79 230 0 0 0
2019-07-05 0 0 0 0 0 0 0 240 0 0 0
2019-07-06 0 0 0 0 0 0 93 220 0 0 0
2019-07-07 0 0 0 0 0 0 229 240 0 240 0
2019-07-08 45 64 0 0 0 0 192 240 0 0 0
2019-07-09 0 81 0 0 0 0 0 235 0 0 0
2019-07-10 65 0 0 0 0 0 96 240 0 0 0
2019-07-11 151 0 0 0 208 0 192 220 0 223 0
2019-07-12 41 48 0 0 0 0 96 231 0 0 0
2019-07-13 198 0 0 0 0 204 0 0 0 0 0
2019-07-14 0 144 0 0 0 0 77 480 0 0 0
2019-07-15 0 0 0 0 0 0 0 192 0 216 0
2019-07-16 48 0 0 0 0 0 0 178 0 0 0
2019-07-17 301 84 0 0 0 0 96 213 0 0 0
2019-07-18 174 240 0 0 0 0 144 0 0 0 221
2019-07-19 74 264 0 0 0 213 0 0 0 0 0
2019-07-20 144 237 0 0 0 0 0 0 0 0 0
2019-07-21 0 288 0 0 0 0 0 0 0 0 0
2019-07-22 0 181 0 0 0 0 0 0 0 0 0
2019-07-24 2 0 0 0 0 0 0 0 0 0 0

Naknek - Kvichak District Drift

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Naknek-Kvichak District Drift") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)

Naknek Section Set

t <- dat.fdms %>%
  filter(DISTRICTCODE == 324) %>%
  filter(SUBDISTRICTCODE %in% c("21","22","23","91")) %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 1243
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
tbl <- table(t$SAMPLINGCODENAME,t$plot.date)
kable(tbl)
2019-06-25 2019-06-29 2019-07-01 2019-07-07 2019-07-11 2019-07-15
Naknek Section Set - Pederson Pt. To N Naknek Pt. 223 207 208 0 0 0
Naknek Section Set - S. Naknek Pt. To Johnson Hill 0 0 0 214 201 190

Naknek SHA Drift

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Naknek SHA Drift") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.43
1.3 0.50
2.2 0.04
2.3 0.02

Naknek Escapement

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Naknek River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.78
1.3 0.18
2.2 0.03
2.3 0.01

Kvichak Section Set

The third sample here (7/2/19) has an age composition that looks very suspicous to me. It has an age comp that looks like naknek section set.

t <- dat.fdms %>%
  filter(DISTRICTCODE == 324) %>%
  filter(SUBDISTRICTCODE %in% c("11","12","13","90")) %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 744
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
tbl <- table(t$SAMPLINGCODENAME,t$plot.date)
kable(tbl)
2019-06-25 2019-06-29 2019-07-02 2019-07-11
Kvichak Section-Set 0 0 210 0
Kvichak Section Set - Graveyard to Libbyville 0 205 0 0
Kvichak Section Set - NW marker to Copenhagen Cr. 138 0 0 191
kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.61
1.3 0.36
2.2 0.03
2.3 0.01

Kvichak Escapement

t <- dat.fdms %>%
  filter(SAMPLINGCODENAME == "Kvichak River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)

Nushagak ASL Overview

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325)

kable(table(t$SAMPLINGCODENAME,t$SUBDISTRICTCODE))
00 10 11 30 31 32 35 41 90
Igushik River Escapement 0 496 0 0 0 0 0 0 0
Igushik Section Set 0 0 1392 0 0 0 0 0 0
Nushagak District Drift 6377 0 0 0 0 0 0 0 0
Nushagak River Escapement 0 0 0 2059 0 0 0 0 0
Nushagak Section Drift 0 0 0 1200 0 0 0 0 0
Nushagak Section Set 0 0 0 0 0 0 0 0 461
Nushagak Section Set - Coffee Pt. 0 0 0 0 0 0 370 0 0
Nushagak Section Set - Combine Flats 0 0 0 0 1440 0 0 0 0
Nushagak Section Set - Queens Slough 0 0 0 0 0 64 0 0 0
Wood River Escapement 0 0 0 1226 0 0 0 0 0
Wood River SHA Set 0 0 0 0 0 0 0 720 0
kable(table(t$SAMPLINGCODENAME,t$PROJECTID))
1 3
Igushik River Escapement 0 496
Igushik Section Set 1392 0
Nushagak District Drift 6377 0
Nushagak River Escapement 0 2059
Nushagak Section Drift 1200 0
Nushagak Section Set 461 0
Nushagak Section Set - Coffee Pt. 370 0
Nushagak Section Set - Combine Flats 1440 0
Nushagak Section Set - Queens Slough 64 0
Wood River Escapement 0 1226
Wood River SHA Set 720 0
tbl <- table(t$plot.date,t$SAMPLINGCODENAME)
kable(tbl)
Igushik River Escapement Igushik Section Set Nushagak District Drift Nushagak River Escapement Nushagak Section Drift Nushagak Section Set Nushagak Section Set - Coffee Pt. Nushagak Section Set - Combine Flats Nushagak Section Set - Queens Slough Wood River Escapement Wood River SHA Set
2019-06-06 0 0 0 1 0 0 0 0 0 0 0
2019-06-07 0 0 0 11 0 0 0 0 0 0 0
2019-06-08 0 0 0 2 0 0 0 0 0 0 0
2019-06-09 0 0 0 10 0 0 0 0 0 0 0
2019-06-10 0 0 0 10 0 0 0 0 0 0 0
2019-06-11 0 0 0 11 0 0 0 0 0 0 0
2019-06-12 0 0 0 7 0 0 0 0 0 0 0
2019-06-13 0 0 0 14 0 0 0 0 0 0 0
2019-06-14 0 0 0 7 0 0 0 0 0 0 0
2019-06-15 0 0 0 48 0 0 0 0 0 0 0
2019-06-16 0 0 0 68 0 0 0 0 0 0 0
2019-06-17 0 0 0 72 0 0 0 0 0 0 0
2019-06-18 0 0 0 30 0 0 0 0 0 0 0
2019-06-19 0 0 0 40 0 0 0 0 0 0 0
2019-06-20 0 0 0 124 0 0 0 0 0 5 0
2019-06-21 0 192 171 139 0 189 0 0 64 48 0
2019-06-22 0 0 406 68 240 0 0 0 0 0 0
2019-06-23 0 0 0 87 480 0 0 0 0 73 0
2019-06-24 0 0 0 55 0 0 96 480 0 0 0
2019-06-25 0 0 213 72 0 0 0 0 0 0 0
2019-06-26 0 240 192 53 0 0 0 0 0 0 0
2019-06-27 0 0 358 41 0 0 0 0 0 0 0
2019-06-28 0 0 240 31 0 0 0 240 0 0 0
2019-06-29 0 0 0 70 0 0 0 240 0 72 0
2019-06-30 2 0 216 79 0 0 0 0 0 48 0
2019-07-01 0 0 0 107 0 16 244 0 0 96 0
2019-07-02 0 0 0 60 0 0 0 240 0 0 0
2019-07-03 0 0 480 50 0 0 0 0 0 82 0
2019-07-04 0 0 247 53 240 0 19 0 0 0 0
2019-07-05 0 240 0 48 0 0 0 0 0 0 0
2019-07-06 0 240 250 25 0 0 0 0 0 0 0
2019-07-07 0 0 480 26 0 0 11 0 0 0 240
2019-07-08 0 0 628 55 0 0 0 0 0 0 0
2019-07-09 0 0 240 58 240 0 0 0 0 46 0
2019-07-10 0 240 0 70 0 0 0 0 0 141 240
2019-07-11 0 0 240 69 0 256 0 0 0 63 0
2019-07-12 0 0 336 44 0 0 0 0 0 75 0
2019-07-13 0 0 240 40 0 0 0 0 0 72 0
2019-07-14 0 0 240 33 0 0 0 0 0 0 0
2019-07-15 0 0 240 20 0 0 0 0 0 69 240
2019-07-16 0 240 480 14 0 0 0 240 0 55 0
2019-07-17 0 0 240 26 0 0 0 0 0 37 0
2019-07-18 0 0 240 19 0 0 0 0 0 0 0
2019-07-19 0 0 0 19 0 0 0 0 0 156 0
2019-07-20 9 0 0 11 0 0 0 0 0 88 0
2019-07-21 0 0 0 10 0 0 0 0 0 0 0
2019-07-22 0 0 0 7 0 0 0 0 0 0 0
2019-07-23 13 0 0 12 0 0 0 0 0 0 0
2019-07-24 59 0 0 8 0 0 0 0 0 0 0
2019-07-25 136 0 0 5 0 0 0 0 0 0 0
2019-07-26 163 0 0 5 0 0 0 0 0 0 0
2019-07-27 114 0 0 5 0 0 0 0 0 0 0
2019-07-28 0 0 0 7 0 0 0 0 0 0 0
2019-07-29 0 0 0 3 0 0 0 0 0 0 0

Nushagak District Drift

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(STREAMCODE == 0) %>%
  filter(SUBDISTRICTCODE == "00") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 5253
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),4),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.4295
1.3 0.5408
2.2 0.0225
2.3 0.0072

Nushagak Section Drift

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(STREAMCODE == 0) %>%
  filter(SUBDISTRICTCODE == "30") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 1041
kable(round(table(t$AGE)/nrow(t),4),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.4323
1.3 0.5408
2.2 0.0192
2.3 0.0077

WRSHA Set

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(SUBDISTRICTCODE == "41") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 619
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.82
1.3 0.16
2.2 0.03

Wood River Escapement

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(SAMPLINGCODENAME == "Wood River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 966
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)
kable(round(table(t$AGE)/nrow(t),2),col.names = c("Age","Proportion"))
Age Proportion
1.2 0.86
1.3 0.11
2.2 0.03
2.3 0.00

Nushagak River Escapement

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(SAMPLINGCODENAME == "Nushagak River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 1317
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)

Igushik River Escapement

t <- dat.fdms %>%
  filter(DISTRICTCODE == 325) %>%
  filter(SAMPLINGCODENAME == "Igushik River Escapement") %>%
  filter(AGE %in% c("1.2","1.3","2.2","2.3"))

print("Total Sample Size")
## [1] "Total Sample Size"
print(nrow(t))
## [1] 354
p <- ggplot(t,aes(plot.date)) +
  geom_bar(aes(fill = AGE), position = "fill")
ggplotly(p)