Error in stanc(file = file, model_code = model_code, model_name = model_name, : parser failed badly
Nobody has claimed this yet.
- Dominant language
- R
- Stars
- 1.1k
- Forks
- 266
- Avg merge
- 2h 56m
- Merged PRs (30d)
- 1
Description
Summary:
The following errors occur when running “stan" function(R4.2.0,stan2.26.1)
Description:
Error in stanc(file = file, model_code = model_code, model_name = model_name, :
parser failed badly
Reproducible Steps:
In order to run the LBA model, an lba_log.stan file was created, and then loaded Stan and data in another r file. Everything was normal until the above error occurs when Stan was running
If you have a reproducible example, please include it.
The running code
rm(list=ls())
setwd("~/lba/")
#source('lba.r')
library(rstan)
#make simualated data
library(openxlsx)
#out = rlba(500,1,1,c(2,1),1,.5)
out = read.xlsx("transp1.xlsx",sheet = 1)
rt = cbind(out[,2],out[,3])
len = length(rt[,1])
#run the Stan model
fit <- stan(file = "lba_log.stan",
data = list(RT=rt,LENGTH=len,NUM_CHOICES=1),
warmup = 75,
iter = 150,
chains = 3)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the R script's stan(file = "lba_log.stan", ...) call and inspect the referenced lba_log.stan model, which is not included in the report. Reproduce the failure with R 4.2.0, rstan 2.26.1, and the listed inputs; done requires an actionable parser diagnosis or a confirmed correction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- r
- Domain
- data
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100