Skip to content
Snippets Groups Projects
Verified Commit cd76880d authored by Tamas Gal's avatar Tamas Gal :speech_balloon:
Browse files

Add examples to docs

parent b56c643d
No related branches found
No related tags found
No related merge requests found
......@@ -11,6 +11,7 @@ makedocs(;
),
pages = [
"Home" => "index.md",
"Examples" => "examples.md",
"API" => "api.md"
],
repo = "https://git.km3net.de/common/KM3io.jl/blob/{commit}{path}#L{line}",
......
# Examples
## Whatever
## Offline data
```@example
Let's use the `KM3NeTTestData` Julia package which contains all kinds of KM3NeT
related sample files. The `datapath()` function can be used to get a path to
such a file. In the following, we will discover the `numucc.root` file which
contains 10 muon neutrino charged current interaction events.
```@example 1
using KM3io, KM3NeTTestData
f = ROOTFile(datapath("offline", "numucc.root"))
```
The `ROOTFile` is the container object which gives access to both the online and
offline tree. In this case, the online tree is empty
```@example 1
print(f.online)
```
and the offline tree holds our 10 MC events:
```@example 1
print(f.offline)
```
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment