Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Latex for graphs like stan_ac, stan_dens, and others #191

Open
UglyDogIsDog opened this issue Oct 27, 2021 · 3 comments
Open

Latex for graphs like stan_ac, stan_dens, and others #191

UglyDogIsDog opened this issue Oct 27, 2021 · 3 comments

Comments

@UglyDogIsDog
Copy link

I wonder if there is a way to transform the parameter names to its greek letter form

@VeenDuco
Copy link
Collaborator

Hey I'm not sure which version you are using. If you use the version 3.0 you could download the rds files associated with the figures. These are ggplot objects so you could manipulate them. e.g. for the divergentScatterPlot you can download the .rds file and load it in and change the axis;

p1 <- readRDS("divergentScatterPlot.rds")
p1 + xlab(expression(mu))

image

Best, Duco

@UglyDogIsDog
Copy link
Author

I use something like

fit_tmp <- fit()
names(fit_tmp) <- paste("$\", names(fit_tmp), "$", sep="")
stan_dens(fit_tmp, row_tmp) +
theme(axis.text.x = element_text(size = 15), axis.text.y = element_text(size = 15))

There are some subgraphs with parameter names such as 'beta[1,1]', 'beta[1,2]'. But they do not automatically render to their greek forms. Do you have some solutions to generate the parameter names in latex?

@VeenDuco
Copy link
Collaborator

The expression() function works to get the greek symbols. See here for example. Hope this helps, Best, Duco

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants