[Latex] Two ways to quickly convert a table to Latex code

Method 1: Online conversion

At present, many online conversion tools, such as TablesGenerator and TableConvert , are currently not accessible to TablesGenerator and seem to be dead. Here, TableConvert is used as an explanation.
TableConvert is a tool that can convert tables online. It supports Markdown tables, CSV, JSON, XML, YAML, SQL, HTML tables, Excel and LaTeX tables, and it also has a built-in table editor that can be edited and used like Microsoft Excel Very convenient.

function list:

  • Convert, edit and generate Markdown tables, CSV, JSON, XML, YAML, SQL, HTML tables, Excel and LaTeX tables
  • Visual table creator
  • A spreadsheet editor similar to Excel, supports keyboard and mouse operations at the same time
  • Extract the table in the URL
  • LaTex table generator
  • Custom output template (IDEA)
  • Compress XML, JSON, HTML, etc.

Insert picture description here
Insert picture description here

Disadvantages:

  • The style of the table cannot be generated automatically
  • It seems that there will be garbled problems when importing the table.

Method two, use Excel2LaTeX plug-in

The Excel2LaTeX plug-in can complete a lot of functions from excel to latex. It has been compiled, just like using exe directly, without installation. Let's take a look at the simple use:
Requirements: Convert the table data into Latex code
Insert picture description here
Steps:
1. Download the plug-in, you can choose to download it on github or I have prepared the network disk address
github download address: https://github.com/
Insert picture description here
You can read the README on krlmlr/Excel2LaTeX github for easy use.
Web Disk Address:
Link: https://pan.baidu.com/s/1JMqjy5Y2FEZBLrzbNOuWQA
Extraction code: 6666
Insert picture description here
2. Directly double-click Excel2LaTeX.xla to open it, check Enable Macro
Insert picture description here
3. Find and open the excel file that needs to be converted, select the conversion area , Find the add-in for excel and click Convert Table to LaTex .

Insert picture description here
4. Uncheck Booktabs package and copy the code to Latex.
Insert picture description here
5. Finally, the import of the macro package in LaTeX is complete.

\usepackage{bigstrut,multirow,rotating,booktabs}%表格插件

Insert picture description here

Guess you like

Origin blog.csdn.net/dl962454/article/details/114176845