get_text: Get HTML text element

View source: R/get_text.R

get_textR Documentation

Get HTML text element

Description

Get HTML text element

Usage

get_text(url, xpath)

Arguments

url

String. The Uniform Resource Locator of the resource of interest.

xpath

String. The XML path to an element of interest.

Value

The string to be found under the given XML path and URL.

Examples

get_text(url = 'https://www.gurufocus.com/stock/AAPL/summary',
xpath = '//*[@id="stock-header"]/div/div[1]/div[1]/div[2]/div/h1/span[1]')

OliverHennhoefer/quant documentation built on Sept. 18, 2022, 5:50 p.m.