Convert-Pheno
view release on metacpan or search on metacpan
- Changed getpwuid to $ENV{'USERNAME'} to make 'MSWin32' compatible
0.11_2 2023-07-10T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)
- Modified Python binding to work in Conda env
- Increased Perl version from 5.16 to 5.26
0.11_1 2023-07-09T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)
- Reverted change in Makefile.PL for 'IO::Socket::SSL'
- IO::Socker::SSL only is used if installed
0.11 2023-07-09T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)
- Uncommented 'IO::Socket::SSL' in Makefile.PL to pass self-validation of mapping schema in t/
- Changed cnag.crg.eu to cnag.eu
0.10 2023-07-03T00:00:00Z (Manuel Rueda <mrueda@cpan.org>)
- Added share/db/{omim,hpo}.db SQLite databases
- Modified source to accomodate such dbs
Note: Versions < 0.10 were primarily for testing deployment on CPAN
Makefile.PL view on Meta::CPAN
'Types::Standard' => '2.004000',
#'Test::Deep' => '1.204',
#'Test::Exception' => '0.43',
#'Test::Warn' => '0.37',
'Data::Leaf::Walker' => '0.21',
'Hash::Fold' => '1.0.0',
'JSONLD' => '0.006',
'Devel::Size' => '0.84',
'DateTime::Format::ISO8601' => '0.17'
#'IO::Socket::SSL' => '2.083'
#'Mojolicious::Plugin::OpenAPI' => '5.09'
},
EXE_FILES => ['bin/convert-pheno'],
TEST_REQUIRES => {
'Test::More' => '1.30',
'Test::Deep' => '1.204',
'Test::Exception' => '0.43',
'Test::Warn' => '0.37'
},
test => { TESTS => 't/*.t' },
bin/convert-pheno view on Meta::CPAN
-min-text-similarity-score <score> Minimum score for cosine similarity (or Sorensen-Dice coefficient) [0.8] (to be used with --search [mixed|fuzzy])
-ohdsi-db Use Athena-OHDSI database (~2.2GB) with -iomop
-omop-tables <tables> OMOP-CDM tables to be processed. Tables <CONCEPT> and <PERSON> are always included.
-out-dir <directory> Output (existing) directory
-O Overwrite output file
-path-to-ohdsi-db <directory> Directory for the file <ohdsi.db>
-phl|print-hidden-labels Print original values (before DB mapping) of text fields <_labels>
-rcd|redcap-dictionary <file> REDCap data dictionary CSV file
-schema-file <file> Alternative JSON Schema for mapping file
-search <type> Type of search [>exact|mixed|fuzzy]
-svs|self-validate-schema Perform a self-validation of the JSON schema that defines mapping (requires IO::Socket::SSL)
-sep|separator <char> Delimiter character for CSV files [;] e.g., --sep $'\t'
-stream Enable incremental processing with -iomop and -obff [>no-stream|stream]
-sql2csv Print SQL TABLES (only valid with -iomop). Mutually exclusive with --stream
-test Does not print time-changing-events (useful for file-based cmp)
-text-similarity-method <method> The method used to compare values to DB [>cosine|dice]
-u|username <username> Set the username
Generic Options:
-debug <level> Print debugging level (from 1 to 5, being 5 max)
-help Brief help message
requires 'Text::CSV_XS';
requires 'Text::Similarity';
requires 'Text::Levenshtein::XS';
requires 'Sort::Naturally';
requires 'DBI';
requires 'Moo';
requires 'DBD::SQLite';
requires 'Mojolicious::Lite';
requires 'XML::Fast';
requires 'JSON::Validator';
requires 'IO::Socket::SSL';
requires 'Types::Standard';
requires 'File::ShareDir::ProjectDistDir';
requires 'Data::Leaf::Walker';
requires 'Hash::Fold';
requires 'JSONLD';
requires 'Devel::Size';
requires 'DateTime::Format::ISO8601';
# t
requires 'Test::Deep';
if ( $Config{archname} =~ /-ld\b/ ) {
plan skip_all => 'Skipping tests on ld architectures due to known issues';
exit;
}
my $ohdsi_db = 'share/db/ohdsi.db';
use_ok('Convert::Pheno') or exit;
# NB: Define constants to allow passing tests
use constant HAS_IO_SOCKET_SSL => defined eval { require IO::Socket::SSL };
use constant IS_WINDOWS => ( $^O eq 'MSWin32' || $^O eq 'cygwin' ) ? 1 : 0;
my $SELF_VALIDATE = IS_WINDOWS ? 0 : HAS_IO_SOCKET_SSL ? 1 : 0;
my $input = {
redcap2bff => {
in_file => 't/redcap2bff/in/redcap_data.csv',
redcap_dictionary => 't/redcap2bff/in/redcap_dictionary.csv',
mapping_file => 't/redcap2bff/in/redcap_mapping.yaml',
schema_file => 'share/schema/mapping.json',
self_validate_schema => $SELF_VALIDATE,
( run in 0.580 second using v1.01-cache-2.11-cpan-4d50c553e7e )