Skip to content

Commit

Permalink
Use only hex on site
Browse files Browse the repository at this point in the history
  • Loading branch information
szimmer committed Oct 4, 2024
1 parent fa08700 commit 835738c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ output: github_document

<!-- README.md is generated from README.Rmd. Please edit that file -->

# srvyrexploR <img src="man/figures/logo/srvyrExplore.png" align="right" height="149" width="149"/>
# srvyrexploR <img src="man/figures/srvyrExplore.png" align="right" height="149" width="149"/>

```{r, include = FALSE}
#| label: setup
Expand Down
14 changes: 8 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

<!-- README.md is generated from README.Rmd. Please edit that file -->

# srvyrexploR <img src="man/figures/logo/srvyrExplore.png" align="right" height="149" width="149"/>
# srvyrexploR <img src="man/figures/srvyrExplore.png" align="right" height="149" width="149"/>

The **srvyexploR** package provides datasets used in the book [Exploring
Complex Survey Data Analysis Using R: A Tidy Introduction with {srvyr}
Expand Down Expand Up @@ -73,7 +73,7 @@ post-election interviews. To load this dataset, we recommend using the
{haven} package as follows:

``` r
anes_stata <- haven::read_dta(system.file("extdata", "anes_2020_stata_example.dta", package="srvyrexploR"))
anes_stata <- haven::read_dta(system.file("extdata", "anes_2020_stata_example.dta", package = "srvyrexploR"))
```

### NCVS
Expand Down Expand Up @@ -209,9 +209,11 @@ pak::pak("gergness/srvyr")
library(srvyr)

recs_des <- recs_2020 %>%
as_survey_rep(weights = NWEIGHT, repweights = NWEIGHT1:NWEIGHT60,
type = "JK1", scale = 59/60, mse = TRUE,
variables=c(ACUsed, Region))
as_survey_rep(
weights = NWEIGHT, repweights = NWEIGHT1:NWEIGHT60,
type = "JK1", scale = 59 / 60, mse = TRUE,
variables = c(ACUsed, Region)
)

recs_des
#> Call: Called via srvyr
Expand All @@ -235,7 +237,7 @@ recs_des
recs_des %>%
group_by(Region) %>%
summarize(
p=survey_mean(ACUsed, vartype="ci", proportion = TRUE, prop_method = "logit")
p = survey_mean(ACUsed, vartype = "ci", proportion = TRUE, prop_method = "logit")
)
#> # A tibble: 4 × 4
#> Region p p_low p_upp
Expand Down
Binary file removed logo.png
Binary file not shown.
File renamed without changes

0 comments on commit 835738c

Please sign in to comment.