Skip to content
项目

关于

适用于 Julia 语言的 Excel 文件读写库。

其他项目

这些数字如何统计

可以做什么

  • Read and write cell values, ranges and whole tables through the Tables.jl interface, so data goes straight to and from a DataFrame
  • Stream the rows of large files with eachrow and eachtablerow, without loading the whole sheet
  • Cell formatting (fonts, fills, borders, alignment, number formats) and conditional formats
  • Formulas and defined names

实测星标增长

24小时
0
7天
0
15天
0
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

XLSX.jl

License CI codecov dev stable DOI

Excel file reader/writer for the Julia language.

Introduction

XLSX.jl is a Julia package to read and write Excel spreadsheet files.

Internally, an Excel XLSX file is just a Zip file with a set of XML files inside. The formats for these XML files are described in the Standard ECMA-376.

This package follows ECMA-376 to parse and generate XLSX files.

Requirements

  • Julia v1.10 (LTS) or more recent

  • Linux, macOS or Windows.

Installation

From a Julia session, run:

julia> using Pkg

julia> Pkg.add("XLSX")

Features

  • Read and write cell values, ranges and whole tables through the Tables.jl interface, so data goes straight to and from a DataFrame
  • Stream the rows of large files with eachrow and eachtablerow, without loading the whole sheet
  • Cell formatting (fonts, fills, borders, alignment, number formats) and conditional formats
  • Formulas and defined names
  • Insert and delete rows and columns, with formulas and everything else that refers to them updated
  • Data validation, including drop-down lists
  • AutoFilter buttons on plain ranges
  • Sheet visibility (hidden and very hidden), tab colours, sheet protection and page setup for printing
  • Native Excel Tables
  • Merged cells, column widths, row heights, hidden and grouped rows and columns, and freeze/split panes
  • Hyperlinks, images and cell comments
  • Native Excel charts: read, format and create (experimental)
  • FileIO.jl integration

See the documentation for guides and the full API.

Quick Start

using XLSX, DataFrames

df = DataFrame(name = ["a", "b", "c"], value = [1.5, 2.5, 3.5])
XLSX.writetable("data.xlsx", df; sheetname = "Data", overwrite = true)

df2 = DataFrame(XLSX.readtable("data.xlsx", "Data"))

XLSX.openxlsx("data.xlsx", mode = "rw") do xf
    sheet = xf["Data"]
    sheet["C1"] = "Total"
    XLSX.setFormula(sheet, "C2", "=SUM(B2:B4)")
    XLSX.setFont(sheet, "C1"; bold = true)
end

Source Code

The source code for this package is hosted at https://github.com/juliadata/XLSX.jl.

License

The source code for the package XLSX.jl is licensed under the MIT License.

Getting Help

If you're having any trouble, have any questions about this package or want to ask for a new feature, just open a new issue.

Contributing

Contributions are always welcome!

To contribute, fork the project on GitHub and send a Pull Request.

References

Alternative Packages

探索相关项目

加载中…