Published November 21, 2020 | Version 1.0

Enhanced Bug Prediction in JavaScript Programs with Hybrid Call-Graph Based Invocation Metrics (Training Dataset)

  • 1. University of Szeged

Description

This dataset consists of multiple files which contain bug prediction training data.

The entries in the dataset are JavaScript functions either being buggy or non-buggy. Bug related information was obtained from the project EsLint contained in BugsJS (https://github.com/BugsJS/eslint). The buggy instances were collected throughout the lifetime of the project, however we added non-buggy entries from the latest version which is tagged as fix (entries which were previously included as buggy were not included as non-buggy later on).

The dataset is based on hybrid call graphs which are constructed by https://github.com/sed-szeged/hcg-js-framework. The result of this tool is a call graph where the edges are associated with a confidence level which shows how likely the given edge is a valid call edge.

We used different threshold values from which we considered the edges to be valid. The following threshold values were used:

  • 0.00
  • 0.05
  • 0.20
  • 0.30

The prefix in the dataset file names are coming from the used threshold. The the datasets include coupling metrics NII (Nubmer of Incoming Invocations) and NOI (Number of Outgoing Invocations) which were calculated by a static source code analyzer called SourceMeter. Hybrid counterparts of these metrics (HNII and HNOI) are based on the given threshold values.

There are four variants for all of these datasets:

  • Both static (NII, NOi) and hybrid (HNII, HNOI) coupling metrics are included with additional static source code metrics and information about the entries (file without any postfix). Column contained only in this dataset are:
    • ID
    • Name
    • Longname
    • Parent ID
    • Component ID
    • Path
    • Line
    • Column
    • EndLine
    • EndColumn
  • Both static (NII, NOi) and hybrid (HNII, HNOI) coupling metrics are included with additional static source code metrics (file with '_h+s' postfix)
  • Only static (NII, NOI) coupling metrics are included with additional static source code metrics (file with '_s' postfix)
  • Only hybrid (HNII, HNOI) coupling metrics are included with additional static source code metrics (file with '_h' postfix)

Static source code metrics which are contained in all dataset are the following:

  • McCC - McCabe Cyclomatic Complexity
  • NL - Nesting Level
  • NLE - Nesting Level Else If
  • CD - Comment Density
  • CLOC - Comment Lines of Code
  • DLOC - Documentation Lines of Code
  • TCD - Total Comment Density (Comment Lines in an emedded function will be also considered)
  • TCLOC - Total Comment Lines of Code (Comment Lines in an emedded function will be also considered)
  • LLOC - Logical Lines of Code (Comment and empty lines not counted)
  • LOC - Lines of Code (Comment and empty lines are counted)
  • NOS - Number of Statements
  • NUMPAR - Number of Parameters
  • TLLOC - Logical Lines of Code (Lines in embedded functions are also counted)
  • TLOC - Lines of Code (Lines in embedded functions are also counted)
  • TNOS - Total Number of Statements (Statements in embedded functions are also counted)

Files

0_00.csv

Files (3.5 MB)

Name Size Download all
md5:46854f2f6613ecea99775b1520e7f1fb
460.3 kB Preview Download
md5:bafd6cf604c684964b5eb14a3c5d6bd8
133.0 kB Preview Download
md5:2c17f69f2371d410f22ade0f7dde3528
144.1 kB Preview Download
md5:a95ad8ac0080e6c27b24351cce425467
132.4 kB Preview Download
md5:1dc74e05fde7a99479e8832378a425bc
460.3 kB Preview Download
md5:9f4228b9c1694cd62de0a69d55418fab
133.0 kB Preview Download
md5:40fb9ff8c547210bda535c3ec0c5ef8d
144.1 kB Preview Download
md5:a95ad8ac0080e6c27b24351cce425467
132.4 kB Preview Download
md5:029e7313c033f67d4fbc0a5794c6a1d9
459.7 kB Preview Download
md5:9e60fa839a373a9ba195989d3f8e589c
132.4 kB Preview Download
md5:676db055050d90173f23e24d35a9b6bf
143.5 kB Preview Download
md5:a95ad8ac0080e6c27b24351cce425467
132.4 kB Preview Download
md5:029e7313c033f67d4fbc0a5794c6a1d9
459.7 kB Preview Download
md5:9e60fa839a373a9ba195989d3f8e589c
132.4 kB Preview Download
md5:676db055050d90173f23e24d35a9b6bf
143.5 kB Preview Download
md5:a95ad8ac0080e6c27b24351cce425467
132.4 kB Preview Download