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

Running head "DISTORTED PD ESTIMATES IN SEQUENCE LEARNING" #561

Closed
LisaSpitzer opened this issue Aug 1, 2023 · 5 comments
Closed

Running head "DISTORTED PD ESTIMATES IN SEQUENCE LEARNING" #561

LisaSpitzer opened this issue Aug 1, 2023 · 5 comments
Assignees
Labels

Comments

@LisaSpitzer
Copy link

LisaSpitzer commented Aug 1, 2023

Describe the bug
I am using papaja version 0.1.1.9001, and have followed the online description to use the settings for APA7. When I'm knitting to Word, the running head is correctly displayed on the first page (Running head: my running head), but on the following pages, it is "DISTORTED PD ESTIMATES IN SEQUENCE LEARNING", which I have not defined in any part of my RMD. A quick Google search indicated it might be based on one of your papers. :D

To Reproduce
This is my YAML header (I have removed personal info):
`---
title : "My title"
shorttitle : "My running head"

author:

  • name : "Lisa Spitzer"
    affiliation : "1"
    corresponding : yes # Define only one corresponding author
    address : "Universitaetsring 15, 54296 Trier"
    email : "my email"
    role: # Contributorship roles (e.g., CRediT, https://credit.niso.org/)
    • "TODO"

affiliation:

  • id : "1"
    institution : "Leibniz Institute for Psychology (ZPID)"

authornote: |
Lisa Spitzer, https://orcid.org/0000-0002-4925-7291

Enter author note here.

abstract: |
(removed)

keywords : "preregistration, open science, meta-research, reproducibility, replicability"
wordcount : "X"

bibliography : ["r-references_edited.bib", "rordof.bib"]

floatsintext : yes
tables : yes
linenumbers : yes
draft : no
mask : no

figurelist : no
tablelist : no
footnotelist : no

classoption : "man"
header-includes:

  • |
    \makeatletter
    \renewcommand{\paragraph}{@startsection{paragraph}{4}{\parindent}%
    {0\baselineskip @plus 0.2ex @minus 0.2ex}%
    {-1em}%
    {\normalfont\normalsize\bfseries\typesectitle}}

    \renewcommand{\subparagraph}[1]{@startsection{subparagraph}{5}{1em}%
    {0\baselineskip @plus 0.2ex @minus 0.2ex}%
    {-\z@\relax}%
    {\normalfont\normalsize\bfseries\itshape\hspace{\parindent}{Replace output_format parameter in apa.table() #1}\textit{\addperi}}{\relax}}
    \makeatother

csl : "r system.file('rmd', 'apa7.csl', package = 'papaja')"
documentclass : "apa7"
output : papaja::apa6_docx
---`

Expected behavior
I expected the running head to be "my running head", but it's "DISTORTED PD ESTIMATES IN SEQUENCE LEARNING" starting on the second page when knitted to word.

Screenshots
image

Thanks for looking into it! :)

@mariusbarth
Copy link
Collaborator

Hi @LisaSpitzer, that's funny! A quick repository-wide search for the words "distorted" or "sequence" did not yield any results, so it seems to me that the running head has to be coming from somewhere else than the papaja sources. Given that the problem only arises with pdf output, I was wondering if you also use a preamble tex file that might contain a line of code that overwrites the short title?

@LisaSpitzer
Copy link
Author

Hi @mariusbarth, thanks for your quick reply! :) I don't have such a tex file, but I also noticed that the error has been only in the last few outputs (before, with the same RDM, I had correct running heads in the word files). I'm not sure when this error arose. If it's only a problem for me, I can live with that (I'll just adjust the running head in the word file). :) I just wanted to let you know in case it's a bigger issue.

@mariusbarth
Copy link
Collaborator

mariusbarth commented Aug 1, 2023

Hi @LisaSpitzer, I think it is definitely worth trying to find out what is going on! It would be super helpful if you could upload a minimal reproducible example with an rmd file that produces the error!

@LisaSpitzer
Copy link
Author

LisaSpitzer commented Aug 1, 2023

Hi @mariusbarth, okay! I was able to reproduce the error with a completely unedited papaja template (i.e., I just opened the APA6 template). The error is present only in Word, not in the PDF output. I have attached the RMD, Word, and PDF files below.

RMD:

---
title             : "The title"
shorttitle        : "Title"

author: 
  - name          : "First Author"
    affiliation   : "1"
    corresponding : yes    # Define only one corresponding author
    address       : "Postal address"
    email         : "my@email.com"
    role: # Contributorship roles (e.g., CRediT, https://credit.niso.org/)
      - "Conceptualization"
      - "Writing - Original Draft Preparation"
      - "Writing - Review & Editing"
  - name          : "Ernst-August Doelle"
    affiliation   : "1,2"
    role:
      - "Writing - Review & Editing"
      - "Supervision"

affiliation:
  - id            : "1"
    institution   : "Wilhelm-Wundt-University"
  - id            : "2"
    institution   : "Konstanz Business School"

authornote: |
  Add complete departmental affiliations for each author here. Each new line herein must be indented, like this line.

  Enter author note here.

abstract: |
  One or two sentences providing a **basic introduction** to the field,  comprehensible to a scientist in any discipline.
  Two to three sentences of **more detailed background**, comprehensible  to scientists in related disciplines.
  One sentence clearly stating the **general problem** being addressed by  this particular study.
  One sentence summarizing the main result (with the words "**here we show**" or their equivalent).
  Two or three sentences explaining what the **main result** reveals in direct comparison to what was thought to be the case previously, or how the  main result adds to previous knowledge.
  One or two sentences to put the results into a more **general context**.
  Two or three sentences to provide a **broader perspective**, readily comprehensible to a scientist in any discipline.
  
  <!-- https://tinyurl.com/ybremelq -->
  
keywords          : "keywords"
wordcount         : "X"

bibliography      : "r-references.bib"

floatsintext      : no
linenumbers       : yes
draft             : no
mask              : no

figurelist        : no
tablelist         : no
footnotelist      : no

classoption       : "man"
output            : papaja::apa6_docx
---

```{r setup, include = FALSE}
library("papaja")
r_refs("r-references.bib")
# Seed for random number generation
set.seed(42)
knitr::opts_chunk$set(cache.extra = knitr::rand_seed)

Methods

We report how we determined our sample size, all data exclusions (if any), all manipulations, and all measures in the study.

Participants

Material

Procedure

Data analysis

We used r cite_r("r-references.bib") for all our analyses.

Results

Discussion

\newpage

References

::: {#refs custom-style="Bibliography"}
:::


[papaja_test.docx](https://github.com/crsh/papaja/files/12229135/papaja_test.docx)
[papaja_test.pdf](https://github.com/crsh/papaja/files/12229136/papaja_test.pdf)

@mariusbarth
Copy link
Collaborator

Ah, great! I think this is a systematic error. @crsh, do you have a first gut feeling why this is happening? Maybe something got mixed up in the docx template or the pre/post processors do not patch the template correctly? Could this be a downstream issue?

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

Successfully merging a pull request may close this issue.

3 participants