We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File unique identifier;Prediction by Naturalis;Probability by Naturalis;True or false by Naturalis;Prediction by iNat;Probability by iNat;True or false by iNat | |
_test_set_3/(Acanthosomatidae) Elasmucha grisea Parent Bug_8.jpg;Elasmucha grisea;0.894348;1;Elasmucha grisea;0.314679;1 | |
_test_set_3/(Aphrophoridae) Aphrophora alni_3.jpg;Aphrophora alni;1;1;Aphrophora alni;0.410643;1 | |
_test_set_3/(Cercopidae) Cercopis vulnerata_2.jpg;Cercopis vulnerata;1;1;Cercopis vulnerata;0.460223;1 | |
_test_set_3/(Cicadellidae) Adarrus ocellaris_3.jpg;Errastunus ocellaris;0.973848;0;Speudotettix subfusculus;0.303513;0 | |
_test_set_3/(Cicadellidae) Aguriahana stellulata_4.jpg;Aguriahana stellulata;0.999827;1;Aguriahana;0.433531;1 | |
_test_set_3/(Cicadellidae) Arthaldeus pascuellus_4.jpg;Arthaldeus pascuellus;1;1;Graminella nigrifrons;0.347305;0 | |
_test_set_3/(Cicadellidae) Athysanus argentarius_5.jpg;Athysanus argentarius;0.999749;1;Athysanus argentarius;0.491078;1 | |
_test_set_3/(Cicadellidae) Batracomorphus irroratus_5.jpg;Iassus lanio;0.699501 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
from statsmodels.tsa.holtwinters import Holt | |
# Load the JSON data | |
with open("pyjamalude-years.json", "r") as file: | |
data = json.load(file) | |
''' | |
Estimate future observation counts based on laji.fi data |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
def process_geojson_with_properties(input_filename, output_filename): | |
# Load the JSON file | |
with open(input_filename, "r") as file: | |
data = json.load(file) | |
# Extract all items under "results" | |
results = data.get("results", []) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import numpy as np | |
import re | |
# Mikko Heikkinen 2020, 2022, 2023 | |
# Defines which columns to use. Order is not significant. | |
usecols = [ | |
'gbifID', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Made with ChatGPT/GPT-4 | |
import requests | |
import pandas as pd | |
import time | |
import csv | |
def fetch_citation_count(doi): | |
""" | |
Function to fetch the citation count for a given DOI using the OpenCitations API. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Made with ChatGPT GPT-4 2023-11-23 | |
# Finds temporal outliers from a simple occurrence data file of a single species from FinBIF, with headers in English. | |
import pandas as pd | |
import seaborn as sns | |
import matplotlib.pyplot as plt | |
from shapely.geometry import Point | |
import geopandas as gpd | |
# Load the data |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Made wth ChatGPT / GPT-4 | |
# Finds spatial ouliers by clcularing SD of locations | |
# Input: FinBIF data of a single species in simple data format | |
import pandas as pd | |
import numpy as np | |
# Load the data (Replace 'file_path' with your actual file path) | |
file_path = 'your_data_file.csv' # Change this to your file path | |
bird_data = pd.read_csv(file_path, sep='\t') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' | |
Converts "Luken aineistokooste 4. lintuatlakseen" tsv file into FinBIF Data Bank secondary data format. | |
Mikko Heikkinen 2023-12-29 | |
''' | |
import pandas as pd | |
# Load the file into a Pandas dataframe using tab as the delimiter. Keep "NA" as a value. | |
file_path = 'luke_atlasdata.txt' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
''' | |
Tool to compare observations from Tiira to atlas data, to see which observations could increase breeding indices. | |
MIT License | |
''' | |
# Source data - Tiira export saved as UTF-8 CSV file | |
tiira_filename = "./import/tiira.csv" | |
# Atlas square to compare to | |
atlas_square = "667:337" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Script to make conversions to a CSV tabular file containing bird species observations (occurrence records) | |
Updated for 2024 file format | |
Data format sample: | |
id;pvm;aika;laji;lkm;ykj_p;ykj_i;PV-indeksi | |
1593921;01.02.2024;07:16;teeri;1;6890000;3410000;2 | |
1593922;01.02.2024;08:04;metso;1;7070000;3380000;2 | |
1593925;01.02.2024;08:17;metso;1;6980000;3230000;2 | |
1593941;01.02.2024;10:39;teeri;80;7090000;3470000;2 |