latex

\textwidth for multicolumn document in LaTeX?

我与影子孤独终老i 提交于 2019-12-07 09:11:54
问题 As this SO Q & A shows, I found that the \textwidth seems confusing. It's the width of text in normal case, but this variable doesn't seem to have the correct info about the width of text with multicols. This is a LaTeX code to print out the width of \textwidth (I copied the code from here). \documentclass[]{article} \usepackage{layouts} \usepackage{multicol} \usepackage[left=20mm,right=20mm,top=33.95mm,bottom=33.95mm]{geometry} \begin{document} textwidth in cm: \printinunitsof{cm}\prntlen{

Scaling plotly figures in knitr Latex document

流过昼夜 提交于 2019-12-07 08:08:58
问题 I'm trying to include a plotly chart into a Latex document with knitr. Since knitr includes the webshot package this works well. But if I want to resize my figure for the latex output, the figure environment gets bigger but the plotly chart is not scalled to the manually set figure width and height. Specifing the webshot options like recommend here, did not work neither. Scaling a ggplot chart works well, but how can I get the same results for the plotly chart? \documentclass{article}

Putting $$s in the middle of an `equation` environment: why doesn't Latex complain?

自闭症网瘾萝莉.ら 提交于 2019-12-07 07:58:39
问题 I was surprised that the Latex code from a recent question didn't throw up any errors, and even more surprised on further investigation, that Crowley's explanation seems to be true. My intuition about the \begin{equation} ... \end{equation} code is clearly off, what's really going on? Consider this, slightly adapted code: \begin{equation} 1: e^{i\pi}+1=0 $$ 2: B\"ob $$ 3: e=mc^2 \end{equation} This seems to prove that Crowley's explanation of such code, namely that "What that code says to

How to get rid of navigation bars in beamer?

梦想的初衷 提交于 2019-12-07 06:47:16
问题 How can I remove the navigation bar of sections and subsections on the top of each slide generated from a beamer latex file? I'm using the package beamerthemesplit. 回答1: The stupid way to make sure the presentation structure does not show up, (independent of theme) comment out the \section and \subsection commands. 回答2: Beamer has different themes you can use, some of which include that navigation bar and some of which don't. The default theme, for example, doesn't include any navigation bar.

Matplotlib xlabel in Arial with one word italicised

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-07 03:15:29
I want to create a matplotlib figure with an x-axis label that is in Arial font, and has one word italicised. I can create figures with x-axis labels in latex-font with one word italicised; I can also create figures with x-axis labels in Arial, as long as I have either the entire label italicised or the entire label normal; but I can't get part of the xlabel in Arial italicised and the other part in arial normal. I'm mostly trying permutations of the following code: from matplotlib import pyplot as plt import numpy as n import matplotlib from matplotlib.font_manager import FontProperties font

Can MathJax render a LaTeX math expression as an image?

大憨熊 提交于 2019-12-07 02:22:49
问题 I know that MathJax can render LaTeX mathematical expressions as text. Can MathJax render LaTeX math expressions as images? I can't find any information about this in the help documentation. If so, could you tell me the details? Thanks! 回答1: I assume you're asking whether MathJax can render math expression as images. Unfortunately, the answer is no: the only output formats are HTML-with-CSS and MathML, according to the documentation. Of course, you could try to convert the resulting HTML+CSS

statsmodels summary to latex

删除回忆录丶 提交于 2019-12-07 01:55:30
问题 I'm a newbie to latex and I want to import a statsmodels(python-package) summary to my report in latex. I found that it's possible to transform a summary into a latex tabular with the following method: latex_as_tabular. Until now everything is working. Now I have to store the tabular, but I don't really understand how this works. I suppose I have to use the following commands: x_values=sm.add_constant(x_values) model=sm.OLS(y_values, x_values) results=model.fit() tbl=results.summary(xname=['b

独家揭秘:CSDN富文本模式(非Markdown模式)下插入数学公式

半腔热情 提交于 2019-12-06 23:50:46
版权声明 :本文为博主Bravo Yeung(知乎UserName同名)的原创文章,欲转载请先私信获博主允许,转载时请附上网址http://blog.csdn.net/lzuacm。 在CSDN上写技术博客时,经常是要插入数学公式的,比如想要说清楚一个算法或单纯要讲一个数学理论。 CSDN新版本博文编辑器支持两种模式,一种是富文本模式,即兼容旧版本的模式; 另一种是Markdown模式。Markdown模式下插入数学公式使用$···$(行内公式)或$$···$ $ (会设置成居中对齐)即可,下面主要介绍富文本模式下如何插入数学公式并解释为什么能这样做。 用Chrome(或 IE)浏览器打开一篇富文本模式下写成的博文,按F12,搜索"mathjax",可以找到如下代码~ <script type="text/javascript" src="https://static-blog.csdn.net/mdeditor/public/res/bower-libs/MathJax/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script> 没错,CSDN富文本模式下能显示LaTex格式的数学公式,并且是基于MathJax的。 富文本模式中插入数学公式主要有下面两种方式: 行间(inline)模式 :即在正文中插入数学内容,公式前后分别插入 \(和

How to debug vim mapping overlaps?

跟風遠走 提交于 2019-12-06 23:38:20
问题 In general how to debug and solve key bindings overlapping? I had this problem.. Recently I add vim-latex plugin to my vim dir. After that I noticed that my ctrl-j bind is overlapped by vim-latex/plugin/imaps.vim and lost a lot of time until solved that. By the way: there is a bug in imaps.vim i think, because there is written " map only if there is no mapping already" and my example shows opposite. 回答1: You can get fine-grained info from the :map command: To show only mappings relevant to a

Can I use a knitr inline expression in the title of a latex document?

廉价感情. 提交于 2019-12-06 20:55:35
问题 I'd like to use a Knitr/Sweave in-line call ( \Sexpr{} ) in the title of a LaTeX document, after the \begin{document} command but before the \maketitle command. The in-line R code would extract one or two pieces of information from an R data-frame created early in the R script I'm embedding in LaTeX. I have a couple of Knitr chunks that create a data.frame from which I derive the information I want to put in the Title. I've tried placing these chunks between LaTeX's \begin{document} call and