Use italic in a list


#1

Hi,

I’m writing an R Markdown document about a data analysis I’m doing. The data are described by two readme files. The first one is very short, so I just use the citation formatting. The second is much longer, and contains a numbered list, so I decided to use italic instead than citation. However, italic seems not to play well with lists:

---
title: "foo"
subtitle: "Andrea"
author: "`r Sys.Date()`"
date: "_reading time: 5 minutes_"
output: rmarkdown::html_vignette
---

```{r setup, include=FALSE}
library(knitr)
opts_chunk$set(warning = FALSE,
               message = FALSE,
               echo    = FALSE,
               fig.align  = "center",
               fig.width = 7.25,
               fig.height = 6)
```

## Read data

A `readme.txt` file is provided with the data, containing the following information which clarifies the data format:

_yadayadaya_

_lorem ipsum_

_The data are provided as a zip-compressed text file with 26 columns of numbers, separated by spaces. Each row is a snapshot of data taken during a single operational cycle, each column is a different variable. The columns correspond to:_

 _1.	unit number
 2.	time, in cycles
 3.	operational setting 1
 4.	operational setting 2
 5.	operational setting 3
 6.	sensor measurement  1
 7.	sensor measurement  2
 .
 .
 .
 26. sensor measurement_

If you render this file, you’ll see that the list is not rendered as, well, a list. Also, is there a way to include empty list items in a list, and skip directly to item 26 in my case? Of course, the dots I used don’t achieve the goal.


#2

Have you tried using a single * on either side of the list?


#3

Hi, yes, I tried but it doesn’t work. You can test it yourself: there was a small error in my R Markdown, but now my code is reproducible.


#4

This should work for you:

<i>

 1.	unit number
 2.	time, in cycles
 3.	operational setting 1
 4.	operational setting 2
 5.	operational setting 3
 6.	sensor measurement  1
 7.	sensor measurement  2

</i>

#5

Perfect! It works. Is that an HTML tag for italic? PS I would like to accept your post as answering my question, but apparently I can’t.


#6

Yes, it is. If you are knitting to an html document than you can use HTML tags in the document.

As for accepting the answer, you can see this post by @mara about how to accept an answer:


#7

Yep, there’s a box, usually, but I cannot see it now. Well, consider your answer accepted :wink: