Questions tagged [automation]

{automation} is about automating certain tasks when creating a (La)TeX document, e.g., with the help of {packages}, custom {macros} or {tools} for {compiling}.

Filter by
Sorted by
Tagged with
0 votes
0 answers
13 views

How to prepare a multicol one word notes in latex, and extract data from excel or csv file [closed]

I have a .csv file that contains questions and answers (Column B contains questions and Column C contains answers) It would be useful if I can able to convert it into a multicol pdf file where ...
0 votes
0 answers
25 views

is there a way to autofill tables in latex like in excel with equations [duplicate]

i would like to be able to auto calculate simple values based on other values already present in the tabular environment or a similar environment i have tried looking on google but couldn't find ...
0 votes
1 answer
41 views

Automation hyperlink from title to relevant Wikipedia page

I would like to hyperlink any subsection to a relevant Wikipedia page while clicking on it. let's say that the name of the subsection is: " Row and column vectors (wiki) " when clicking on (...
  • 5
2 votes
2 answers
95 views

Define categorized, changeable variables for use throughout a document

TL;DR How do I print categorized and subcategorized values declared in a JSON file (or in some similar type of file) inside of a LaTeX document? In my document, I am assigning a bunch of values to ...
  • 165
1 vote
1 answer
35 views

Automatically generate two-page index entries

I'm writing a text where there will be several index entries for short biographies. The index entries for persons are supposed to be in small caps and the biography entries will get page numbers in ...
  • 1,768
3 votes
1 answer
48 views

Automatically suppress claim number if there's only one claim

When writing a proof, I often need to include a claim, for which I've defined a separate environment. In my current set up, claims are numbered successively, with the numbering resetting within every ...
0 votes
0 answers
41 views

Automating the Build and View (F5)

Is there a way to automate the Build and View (F5) function such that it knows which command to use amongst latex, pdflatex, xetex and lualatex? For example, if I load the fontspec, I want my ...
  • 492
0 votes
1 answer
54 views

Loop through directory structure and include all *.pdf files

I have a document that is constructed from a number of *.tex files stored in a directory organized as follows: -2022 -07 -01 -note.tex -file1.pdf -differentfilename....
1 vote
2 answers
53 views

How do I know, whether I need to run BibTeX or not?

If I have an unknown *.tex file and want to know, whether I need to run BiBTeX afterwards or not, what is the simplest way to find out in a script? Consider this file: \documentclass{article} \begin{...
  • 4,868
1 vote
0 answers
56 views

Polynomial long division with complex numbers

I heard of the polynom LaTeX package, which can be used to do polynomial long division in LaTeX documents; I have even used it myself before for normal polynomials with real coefficients. However, now ...
0 votes
2 answers
64 views

Change vertex and edge style

I wanted the larger circle to be an ellipse, and the loop on the right to be smaller (as the below drawing shows). Does anyone know how to do it? this is my .TEX document: \documentclass[12pt]{...
  • 113
3 votes
3 answers
239 views

LaTeX software to evaluate expressions

I am looking for a latex package that can evaluate symbolic expressions by substituting the values of symbols declared in some header. For example, in these set of equations, as you can see, I get ...
  • 161
1 vote
3 answers
259 views

Get number of pages in document [duplicate]

When writing reports it is common to have a page of meta-information at the start, written by, checked by, client, date etc. One of the fields I need is number of pages. Since I'm going to be ...
  • 1,173
2 votes
0 answers
23 views

Margin when using auto-scaling of parenthesis: Is there a better way than adjusting for it with "\!"?

Whenever I need larger parenthesis I use \left( \right) which automatically adjusts the size as needed. I know that the optimum would be to always manually choose from \big, \bigg, \Big, ... but for ...
  • 187
0 votes
1 answer
33 views

Priority based removal of optional sentences to fit page

I am wasting days of my life rewriting rejected papers for other conferences with different page limits. Also it would be nice to extract parts for a website without a page limit. Is there a way to ...
3 votes
1 answer
284 views

lua code inside directlua throws an invalid escape sequence error

I'm trying to make use of lualatex to automate generation of some part of a pdf. The directory tree for my minimal working example looks like the following: │ lua_escaping_issue.tex │ └───a_folder ...
  • 1,460
0 votes
3 answers
128 views

Create a function that generates a letter?

I have to write many letters where each time I have to modify just the names, dates and address, but it is always the same content. A short version would be something like "Dear [name], from [...
  • 195
1 vote
1 answer
198 views

Automatically adding images directly from python code (preferably using VSCode)

Imagine I have some python code that generates an image. e.g. import matplotlib.pyplot as plt import numpy as np # Data for plotting t = np.arange(0.0, 2.0, 0.01) s = 1 + np....
0 votes
0 answers
23 views

How to ignore theorems when creating a pdf?

I am writing a document which includes exercises and their solution. To do distinguish them nicely, I used the amsthm package and the following code: \newtheoremstyle{dotlessP}{}{}{\color{black}}{}{\...
  • 61
3 votes
2 answers
197 views

How to Left Justify the Lettrine Only with the Text After Inserting Opening Quotation Marks

Consider the code: \documentclass{book} \usepackage{lettrine,xcolor} \usepackage{lipsum} \usepackage[tracking=true]{microtype} \input GoudyIn.fd \renewcommand{\LettrineFontHook}{\usefont{U}{GoudyIn}{...
  • 5,679
0 votes
1 answer
55 views

How to automate table generation via function or macro

This should a simple question with a simple answer but I couldn't find something related to this online (being also a TeX newbie...). I am trying to automate table generation so that I can avoid copy ...
  • 3
0 votes
0 answers
67 views

Scaling tables between page sizes, and filling the page

I'm a teacher, and this is a design pattern I hope to use a lot. I have some information that I want to present as 1) a poster (a1), and 2) a handout (a4). What I would like to be able to do is set ...
1 vote
1 answer
89 views

Enumerate in Beamer: Automize only@

I would like to split enumerate environment over multiple slides in an automatized manner. In the following example, I need to write only@ for each slide. How to get an automized version of this code?...
  • 1,657
3 votes
1 answer
310 views

How to reset alternating row colors using xcolor and longtable?

I am attempting to automate alternating row colors in a longtable environment. My rows alternate between gray and white, and the alternating persists across pagebreaks. My issue is that I would like ...
  • 83
2 votes
1 answer
83 views

Algorithmically generating the syntax of math equations

Is there a way to algorithmically write equation syntax in latex?? Suppose I want to write the N-point DFT matrix in an equation, then is it possible if i specify what each entry of NxN matrix will be ...
  • 161
0 votes
1 answer
54 views

Create .bat to execute XeLaTeX+MakeIndex+BibLaTeX

Time ago I created a bat script to execute PDFLaTeX+MakeIndex+BibLaTeX so I can add as a processing tool in TeXworks (image below), and it was easy because I found many sites explaining how to do that ...
1 vote
1 answer
68 views

Can't write to aux file from cmd

I have an automating script written in Java to generate a PDF file from a source tex file. The?main tex file may reside in one drive say 'C:' and one included file via \input in another drive say 'D:'....
  • 1,187
3 votes
1 answer
46 views

How can I automate file inclusion using arguments?

I am working on a collection of books that uses content from other files. I want to have each reference in a file to avoid redundant content and to make it easier to review and correct the content. ...
  • 443
0 votes
0 answers
28 views

Drawing line from point to automatically fitted linear regression [duplicate]

Hi I have the following code which produces the regression straight based on the points on the table. I suppose the red dots on the curve are the equivalent of each point but on the fitted straight. I ...
1 vote
0 answers
35 views

Float if not larger than otherwise be page-breakable

In my thesis I am embedding a few pseudocode algorithms using the algpseudocode and the algorithm packages. Thus a typical example would look like \begin{algorithm} \caption{My caption} \label{alg:...
  • 2,437
1 vote
0 answers
53 views

Stop LyX from automatically wrapping formulas with LRE (in Hebrew)

As in the following question, I'm working in LyX in Hebrew, by using the "use non-TeX fonts (via XeTeX/LuaTeX)" option. When I insert a math equation LyX automatically wraps it with \LRE{}. ...
  • 297
1 vote
3 answers
142 views

How to automatically generate data summary at the beginning of the document?

Within my report I want do define several structural damages and I want to automatically generate a summary table at the beginning of the document. Here is an example of how far I have come so far and ...
1 vote
1 answer
37 views

Automatically register arguments a command is used with

I am wondering whether it is possible to create some sort of set to keep track of elements in latex. One intended usage would be to automatically generate a list of arguments that have been passed to ...
  • 187
1 vote
2 answers
105 views

Automatically composing documents from multiple text files which are not LaTeX formatted?

I'm looking for a way to create a songbook out of individual song files. Each song file is a self-contained block of text data consisting of: Song name Song author Some details (optional) Lyrics with ...
0 votes
1 answer
53 views

Automatically include a listing of all files in a folder [duplicate]

My thesis supervisor requires me to include all my MATLAB code in the PDF. My code is scattered in a dozen .m files, all in the same folder. I know I can include code, using the matlab-prettifier ...
1 vote
0 answers
86 views

Redefining questions environment in exam to use longtable

I am trying to redefine the questions environment and take each question and put it inside a longtable environment so that the first column will have the question number, and the middle will have the ...
  • 1,884
0 votes
1 answer
74 views

Is there a way to iterate over a list of couple in tikz?

I would like to draw a list of 2D points with tikz and additionally draw these points multiplied by a certain factor alpha. If the y-coordinate was a function of the x-coordinate, it would be easy to ...
1 vote
0 answers
49 views

Automate drawing diagram parsed from input file

I want to automate the process of drawing simple diagrams based on values in an input file. I run simulations and often draw these kinds of diagrams to visualize the parameters. I have used the ...
4 votes
1 answer
117 views

A small tool to simplify the units of measurement using siunitx package

Considering that some of my students, especially first year students (14 years old) are not able to simplify units of measure and find the final unit of measure, is it possible to create an automatic ...
  • 46.8k
1 vote
1 answer
93 views

How to globally apply all texts as the argument of a command?

I'm trying to make an entire document to look like handwrote. For that I tried both the Cthulhu and handlatex. Both of them require the following usage: \command{here the text to be applied.} Which ...
's user avatar
1 vote
1 answer
78 views

Aligning bullet in tikz with some other issues

I want to change a few things in the following picture: (1) Aligning the bullet (d) vertically upwards from where the picture starts. (2) Changing direction of the arrow at q4 from right to left (in ...
1 vote
1 answer
47 views

Automatically remove indentation at natural breaks

I've been using Latex for about 2 years now and I'm really enjoying it. I was just wondering if there is some package or code out there that can help me suppress indents at natural breaks. With ...
2 votes
1 answer
860 views

How do I automatically fill LaTeX templates with from a table of data?

I have a LaTeX template like \documentclass[12pt]{article} \begin{document} Hello, \VAR{USER}! \end{document} and a table of users (for example as a csv) like ID,USER 01,Peter 02,Michael 03,Jana ... ...
0 votes
1 answer
52 views

Footnote with automatic final period not working with "Ibid."

I'm using this solution to automatically add a period at the end of every footnote; the code should insert a period only if the footnote does not already end with a period, a question mark or a bang. ...
  • 81
2 votes
1 answer
145 views

Automate data input

I have a tex body which looks something like This week we have added 5600 vaccines in the inventory which is a 8.5% increase compared to last week. Now, these number, 5600 and 8.5% are updated every ...
  • 127
1 vote
0 answers
71 views

Automation of slave code compilation in master/slave with \newif

For big documents, I choose to use a master/slave structure. Rather than play comment/uncomment the preamble of the slave code with the comment package and also the \end{document} (for avoid conflict ...
4 votes
2 answers
98 views

Define macros from a list processed by the listofitems package

I wanted to distinguish the control variables of different agents in a separate color so that my students can read examples more easily. To do so, I wanted to write a macro \definevar{x,y;z} that I ...
1 vote
0 answers
48 views

Automatically generate tabel that shows grade corresponding to number of points within exam

I would like to automatically add a table that shows the height of the grade corresponging to the number of points. So far, I have \tcprintroundresult{1} \tcsetcoltype{|c|c|}{>{\centering\...
0 votes
1 answer
249 views

How to set `\autocite{}` of `biblatex` as `\tiny` using beamer

I would like to produce beamer slides with biblatex and to set the font size of the citations with \autocite{} as \tiny while keeping the font size of the citations with \textcite default (\normalsize)...
3 votes
1 answer
106 views

Automated lettrine and commands

I need to automatically place lettrines on a text I don't want to edit directly. So far I have been using \def\drop #1#2 {% note the space before { \lettrine{#1}{#2} % a trailing space } and \drop ...
  • 33

1
2 3 4 5
12