read_pagexml: Read Page-XML file

View source: R/alto.R

read_pagexmlR Documentation

Read Page-XML file

Description

Import Page-XML file as a data.frame. Examples where this can be used is for importing page-xml files from Transkribus

Usage

read_pagexml(x, type = c("transkribus"), ...)

Arguments

x

path to the xml file

type

character string with the type of xml structure. Defaults to 'transkribus' and is currently the only option.

...

further arguments currently not used

Value

a data.frame with columns file, id, coords and baseline

Note

the function only handles single-page XML's

Examples

f <- system.file(package = "madoc.utils", "extdata", "pagexml-example.xml")
x <- read_pagexml(f)
f <- system.file(package = "madoc.utils", "extdata", "multiregion-page.xml")
x <- read_pagexml(f)

DIGI-VUB/madoc.utils documentation built on Sept. 14, 2022, 3:03 p.m.