From 5d8035a5b6697fd6bcb928acc65397f23e92c56f Mon Sep 17 00:00:00 2001 From: udaykiranrage Date: Fri, 24 Nov 2023 12:36:55 +0900 Subject: [PATCH] changes --- PAMI/extras/DF2DB/DF2DB.py | 8 +-- PAMI/extras/DF2DB/DF2DBPlus.py | 8 +-- .../{DenseFormatDF2DB.py => DenseFormatDF.py} | 14 ++-- ...SparseFormatDF2DB.py => SparseFormatDF.py} | 14 ++-- PAMI/extras/DF2DB/denseDF2DBPlus.py | 16 ++--- PAMI/extras/DF2DB/denseDF2DB_dump.py | 14 ++-- PAMI/extras/DF2DB/sparseDF2DBPlus.py | 14 ++-- PAMI/extras/dbStats/TemporalDatabase.py | 38 +++++------ docs/dataFrameCoversion.md | 4 +- docs/examples.md | 6 +- docs/exercises/fuzzyFrequentPatternMining.md | 6 +- .../peirodicFrequentPatternMining.md | 6 +- docs/index.md | 6 +- docs/index.md.bak | 6 +- docs/manual.md | 6 +- docs/manuals/DF2DBPlus.md | 20 +++--- docs/manuals/denseDF2DB.md | 12 ++-- docs/manuals/index.md | 4 +- docs/manuals/sparseDF2DB.md | 65 +++++++++--------- docs/manuals/terminalExecute.md | 6 +- docs/plotItemFrequencies.md | 6 +- docs/plotTransactionDistribution.md | 6 +- docs/useAlgo.md | 6 +- htmlDocs/PAMI.extras.DF2DB.rst | 16 ++--- htmlDocs/_build/html/PAMI.extras.DF2DB.html | 66 +++++++++---------- htmlDocs/_build/html/PAMI.extras.dbStats.html | 18 ++--- htmlDocs/_build/html/PAMI.extras.html | 36 +++++----- htmlDocs/_build/html/PAMI.html | 10 +-- .../_modules/PAMI/extras/DF2DB/DF2DBPlus.html | 8 +-- .../PAMI/extras/DF2DB/denseDF2DB.html | 44 ++++++------- .../PAMI/extras/DF2DB/denseDF2DBPlus.html | 42 ++++++------ .../PAMI/extras/DF2DB/sparseDF2DB.html | 26 ++++---- .../PAMI/extras/DF2DB/sparseDF2DBPlus.html | 24 +++---- .../dbStats/transactionalDatabaseStats.html | 66 +++++++++---------- htmlDocs/_build/html/_modules/index.html | 10 +-- .../html/_sources/PAMI.extras.DF2DB.rst.txt | 16 ++--- .../html/_sources/PAMI.extras.dbStats.rst.txt | 4 +- htmlDocs/_build/html/genindex.html | 34 +++++----- htmlDocs/_build/html/py-modindex.html | 6 +- htmlDocs/_build/html/searchindex.js | 2 +- notebooks/CMine.ipynb | 4 +- notebooks/CoMine.ipynb | 4 +- notebooks/FTApriori.ipynb | 4 +- ...PeriodicPatternsInMultipleTimeSeries.ipynb | 4 +- notebooks/airPollutionAnalytics.ipynb | 2 +- .../correlatedPattern/basic/CoMine.ipynb | 4 +- .../correlatedPattern/basic/CoMinePlus.ipynb | 4 +- notebooks/coveragePattern/basic/CMine.ipynb | 4 +- notebooks/coveragePattern/basic/CPPG.ipynb | 4 +- notebooks/extras/DF2DB/denseDF2DB.ipynb | 16 ++--- notebooks/extras/DF2DB/denseFrame.ipynb | 4 +- ...MultipleTimeSeriesFuzzyDatabaseStats.ipynb | 4 +- .../dbStats/temporalDatabaseStats.ipynb | 4 +- .../dbStats/transactionalDatabaseStats.ipynb | 10 +-- .../basic/FTFPGrowth.ipynb | 4 +- notebooks/frequentPattern/basic/Apriori.ipynb | 4 +- notebooks/frequentPattern/basic/ECLAT.ipynb | 4 +- .../frequentPattern/basic/ECLATbitset.ipynb | 4 +- .../frequentPattern/basic/FPGrowth.ipynb | 4 +- notebooks/frequentPattern/closed/CHARM.ipynb | 4 +- .../frequentPattern/maximal/MaxFPGrowth.ipynb | 4 +- .../basic/FSPGrowth.ipynb | 4 +- notebooks/knowledgeDiscoveryInData.ipynb | 8 +-- notebooks/parallelFPGrowth.ipynb | 4 +- ...alPeriodicPatternMiningPollutionDemo.ipynb | 4 +- ...icFrequentPatternMiningPollutionDemo.ipynb | 4 +- .../basic/RSFPGrowth.ipynb | 4 +- .../weightedFrequentPatterns/basic/WFIM.ipynb | 4 +- 68 files changed, 425 insertions(+), 426 deletions(-) rename PAMI/extras/DF2DB/{DenseFormatDF2DB.py => DenseFormatDF.py} (95%) rename PAMI/extras/DF2DB/{SparseFormatDF2DB.py => SparseFormatDF.py} (91%) diff --git a/PAMI/extras/DF2DB/DF2DB.py b/PAMI/extras/DF2DB/DF2DB.py index ab7b9673..f907fdf4 100644 --- a/PAMI/extras/DF2DB/DF2DB.py +++ b/PAMI/extras/DF2DB/DF2DB.py @@ -32,8 +32,8 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . """ -from PAMI.extras.DF2DB.DenseFormatDF2DB import * -from PAMI.extras.DF2DB.SparseFormatDF2DB import * +from PAMI.extras.DF2DB.denseDF2DB import * +from PAMI.extras.DF2DB.sparseDF2DB import * import sys class DF2DB: @@ -76,9 +76,9 @@ def __init__(self, inputDF, thresholdValue, condition, DFtype='sparse') -> None: self.condition = condition self.DFtype = DFtype.lower() if DFtype == 'sparse': - self.DF2DB = sparseFormatDF2DB(self.inputDF, self.condition, self.thresholdValue) + self.DF2DB = sparseDF2DB(self.inputDF, self.condition, self.thresholdValue) elif DFtype == 'dense': - self.DF2DB = DenseFormatDF2DB(self.inputDF, self.condition, self.thresholdValue) + self.DF2DB = denseDF2DB(self.inputDF, self.condition, self.thresholdValue) else: raise Exception('DF type should be sparse or dense') diff --git a/PAMI/extras/DF2DB/DF2DBPlus.py b/PAMI/extras/DF2DB/DF2DBPlus.py index 58da0c58..f770b613 100644 --- a/PAMI/extras/DF2DB/DF2DBPlus.py +++ b/PAMI/extras/DF2DB/DF2DBPlus.py @@ -31,8 +31,8 @@ along with this program. If not, see . """ -from PAMI.extras.DF2DB.DenseFormatDF2DBPlus import * -from PAMI.extras.DF2DB.sparseFormatDF2DBPlus import * +from PAMI.extras.DF2DB.DenseFormatDFPlus import * +from PAMI.extras.DF2DB.SparseFormatDFPlus import * import sys @@ -72,9 +72,9 @@ def __init__(self, inputDF, thresholdConditionDF, DFtype='sparse') -> None: self.thresholdConditionDF = thresholdConditionDF self.DFtype = DFtype.lower() if DFtype == 'sparse': - self.DF2DB = sparseFormatDF2DBPlus(self.inputDF, self.thresholdConditionDF) + self.DF2DB = SparseFormatDFPlus(self.inputDF, self.thresholdConditionDF) elif DFtype == 'dense': - self.DF2DB = DenseFormatDF2DBPlus(self.inputDF, self.thresholdConditionDF) + self.DF2DB = DenseFormatDFPlus(self.inputDF, self.thresholdConditionDF) else: raise Exception('DF type should be sparse or dense') diff --git a/PAMI/extras/DF2DB/DenseFormatDF2DB.py b/PAMI/extras/DF2DB/DenseFormatDF.py similarity index 95% rename from PAMI/extras/DF2DB/DenseFormatDF2DB.py rename to PAMI/extras/DF2DB/DenseFormatDF.py index bbdb9fc8..2f72e666 100644 --- a/PAMI/extras/DF2DB/DenseFormatDF2DB.py +++ b/PAMI/extras/DF2DB/DenseFormatDF.py @@ -1,11 +1,11 @@ -# DenseFormatDF2DB in this code the dense dataframe is converting databases into different transactional, temporal, utility types. +# DenseFormatDF in this code the dense dataframe is converting databases into different transactional, temporal, utility types. # # **Importing this algorithm into a python program** # -------------------------------------------------------- # -# from PAMI.extras.DF2DB import DenseFormatDF2DB as db +# from PAMI.extras.DF2DB import DenseFormatDF as db # -# obj = db.DenseFormatDF2DB(idf, ">=", 16) +# obj = db.DenseFormatDF(idf, ">=", 16) # # obj.save(oFile) # @@ -49,7 +49,7 @@ } -class DenseFormatDF2DB: +class DenseFormatDF: """ :Description: This class create Data Base from DataFrame. @@ -65,9 +65,9 @@ class DenseFormatDF2DB: -------------------------------------------------------- .. code-block:: python - from PAMI.extras.DF2DB import DenseFormatDF2DB as db + from PAMI.extras.DF2DB import DenseFormatDF as db - obj = db.DenseFormatDF2DB(iDdf, ">=", 16 ) + obj = db.DenseFormatDF(iDdf, ">=", 16 ) obj.convert2TransactionalDatabase("outputFileName") # To create transactional database @@ -266,7 +266,7 @@ def getFileName(self) -> str: # Dataframes do not run from a terminal # if __name__ == '__main__': -# obj = DenseFormatDF2DB(sys.argv[1], sys.argv[2], sys.argv[3]) +# obj = DenseFormatDF(sys.argv[1], sys.argv[2], sys.argv[3]) # obj.convert2TransactionalDatabase(sys.argv[4]) # transactionalDB = obj.getFileName() # print(transactionalDB) \ No newline at end of file diff --git a/PAMI/extras/DF2DB/SparseFormatDF2DB.py b/PAMI/extras/DF2DB/SparseFormatDF.py similarity index 91% rename from PAMI/extras/DF2DB/SparseFormatDF2DB.py rename to PAMI/extras/DF2DB/SparseFormatDF.py index c5c67334..0fa09e9e 100644 --- a/PAMI/extras/DF2DB/SparseFormatDF2DB.py +++ b/PAMI/extras/DF2DB/SparseFormatDF.py @@ -1,11 +1,11 @@ -# sparseFormatDF2DB in this code the dense dataframe is converting databases into different transactional, temporal, utility types. +# SparseFormatDF in this code the dense dataframe is converting databases into different transactional, temporal, utility types. # # **Importing this algorithm into a python program** # -------------------------------------------------------- # -# from PAMI.extras.DF2DB import sparseFormatDF2DB as db +# from PAMI.extras.DF2DB import SparseFormatDF as db # -# obj = db.sparseFormatDF2DB(idf, ">=", 16) +# obj = db.SparseFormatDF(idf, ">=", 16) # # obj.save(oFile) # @@ -38,7 +38,7 @@ import pandas as pd import sys -class sparseFormatDF2DB: +class SparseFormatDF: """ :Description: This class create Data Base from DataFrame. @@ -55,9 +55,9 @@ class sparseFormatDF2DB: -------------------------------------------------------- .. code-block:: python - from PAMI.extras.DF2DB import sparseFormatDF2DB as db + from PAMI.extras.DF2DB import SparseFormatDF as db - obj = db.sparseFormatDF2DB(iDdf, ">=", 16) + obj = db.SparseFormatDF(iDdf, ">=", 16) obj.save(oFile) @@ -155,6 +155,6 @@ def getFileName(self) -> str: if __name__ == '__main__': - obj = sparseFormatDF2DB(sys.argv[1], sys.argv[2]) + obj = SparseFormatDF(sys.argv[1], sys.argv[2]) obj.getFileName(sys.argv[3]) diff --git a/PAMI/extras/DF2DB/denseDF2DBPlus.py b/PAMI/extras/DF2DB/denseDF2DBPlus.py index 2f204958..9ada254d 100644 --- a/PAMI/extras/DF2DB/denseDF2DBPlus.py +++ b/PAMI/extras/DF2DB/denseDF2DBPlus.py @@ -1,11 +1,11 @@ -# DenseFormatDF2DBPlus in this code the dense dataframe is converting databases into different transactional, temporal, utility types. +# DenseFormatDFPlus in this code the dense dataframe is converting databases into different transactional, temporal, utility types. # # **Importing this algorithm into a python program** # -------------------------------------------------------- # -# from PAMI.extras.DF2DB import DenseFormatDF2DBPlus as db +# from PAMI.extras.DF2DB import DenseFormatDFPlus as db # -# obj = db.DenseFormatDF2DBPlus(idf, ">=", 16) +# obj = db.DenseFormatDFPlus(idf, ">=", 16) # # obj.save(oFile) # @@ -39,7 +39,7 @@ import pandas as pd import sys -class DenseFormatDF2DBPlus: +class DenseFormatDFPlus: """ :Description: This class create Data Base from DataFrame. @@ -53,9 +53,9 @@ class DenseFormatDF2DBPlus: -------------------------------------------------------- .. code-block:: python - from PAMI.extras.DF2DB import DenseFormatDF2DBPlus as db + from PAMI.extras.DF2DB import DenseFormatDFPlus as db - obj = db.DenseFormatDF2DBPlus(iDdf, ">=", 16) + obj = db.DenseFormatDFPlus(iDdf, ">=", 16) obj.save(oFile) @@ -171,6 +171,6 @@ def getFileName(self) -> str: return self.outputFile if __name__ == '__main__': - a = DenseFormatDF2DBPlus(sys.argv[1], sys.argv[3]) - a.DenseFormatDF2DBPlus() + a = DenseFormatDFPlus(sys.argv[1], sys.argv[3]) + a.DenseFormatDFPlus() diff --git a/PAMI/extras/DF2DB/denseDF2DB_dump.py b/PAMI/extras/DF2DB/denseDF2DB_dump.py index 96fc4c49..bd3cf18f 100644 --- a/PAMI/extras/DF2DB/denseDF2DB_dump.py +++ b/PAMI/extras/DF2DB/denseDF2DB_dump.py @@ -1,11 +1,11 @@ -# DenseFormatDF2DB_dump in this code the dense dataframe is converting databases into different transactional, temporal, utility types. +# DenseFormatDF_dump in this code the dense dataframe is converting databases into different transactional, temporal, utility types. # # **Importing this algorithm into a python program** # -------------------------------------------------------- # -# from PAMI.extras.DF2DB import DenseFormatDF2DB_dump as db +# from PAMI.extras.DF2DB import DenseFormatDF_dump as db # -# obj = db.DenseFormatDF2DB_dump(idf, ">=", 16) +# obj = db.DenseFormatDF_dump(idf, ">=", 16) # # obj.save(oFile) # @@ -38,7 +38,7 @@ import pandas as pd import sys -class DenseFormatDF2DB(): +class DenseFormatDF(): """ :Description: This class create Data Base from DataFrame. @@ -53,9 +53,9 @@ class DenseFormatDF2DB(): -------------------------------------------------------- .. code-block:: python - from PAMI.extras.DF2DB import DenseFormatDF2DB_dump as db + from PAMI.extras.DF2DB import DenseFormatDF_dump as db - obj = db.DenseFormatDF2DB_dump(iDdf, ">=", 16) + obj = db.DenseFormatDF_dump(iDdf, ">=", 16) obj.save(oFile) @@ -303,6 +303,6 @@ def getFileName(self) -> str: if __name__ == '__main__': - obj = DenseFormatDF2DB(sys.argv[1], sys.argv[2]) + obj = DenseFormatDF(sys.argv[1], sys.argv[2]) obj.getFileName(sys.argv[3]) diff --git a/PAMI/extras/DF2DB/sparseDF2DBPlus.py b/PAMI/extras/DF2DB/sparseDF2DBPlus.py index 4b05cde9..7ca7b747 100644 --- a/PAMI/extras/DF2DB/sparseDF2DBPlus.py +++ b/PAMI/extras/DF2DB/sparseDF2DBPlus.py @@ -1,11 +1,11 @@ -# sparseFormatDF2DBPlus in this code the dense dataframe is converting databases into different transactional, temporal, utility types. +# SparseFormatDFPlus in this code the dense dataframe is converting databases into different transactional, temporal, utility types. # # **Importing this algorithm into a python program** # -------------------------------------------------------- # -# from PAMI.extras.DF2DB import sparseFormatDF2DBPlus as db +# from PAMI.extras.DF2DB import SparseFormatDFPlus as db # -# obj = db.sparseFormatDF2DBPlus(idf, ">=", 16) +# obj = db.SparseFormatDFPlus(idf, ">=", 16) # # obj.save(oFile) # @@ -38,7 +38,7 @@ import pandas as pd import sys -class sparseFormatDF2DBPlus: +class SparseFormatDFPlus: """ :Description: This class create Data Base from DataFrame. @@ -52,9 +52,9 @@ class sparseFormatDF2DBPlus: -------------------------------------------------------- .. code-block:: python - from PAMI.extras.DF2DB import sparseFormatDF2DBPlus as db + from PAMI.extras.DF2DB import SparseFormatDFPlus as db - obj = db.sparseFormatDF2DBPlus(iDdf, ">=", 16) + obj = db.SparseFormatDFPlus(iDdf, ">=", 16) obj.save(oFile) @@ -151,5 +151,5 @@ def getFileName(self) -> str: if __name__ == '__main__': - obj = sparseFormatDF2DBPlus(sys.argv[1], sys.argv[2]) + obj = SparseFormatDFPlus(sys.argv[1], sys.argv[2]) obj.getFileName(sys.argv[3]) diff --git a/PAMI/extras/dbStats/TemporalDatabase.py b/PAMI/extras/dbStats/TemporalDatabase.py index 17e828f8..7a750ef9 100644 --- a/PAMI/extras/dbStats/TemporalDatabase.py +++ b/PAMI/extras/dbStats/TemporalDatabase.py @@ -30,6 +30,7 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . """ + import sys import statistics import pandas as pd @@ -100,8 +101,7 @@ class TemporalDatabase: """ - - def __init__(self, inputFile: Union[str, pd.DataFrame], sep: str='\t') -> None: + def __init__(self, inputFile: Union[str, pd.DataFrame], sep: str = '\t') -> None: """ :param inputFile: input file name or path :type inputFile: str @@ -167,7 +167,7 @@ def readDatabase(self) -> None: for ts in timeStampList: self.periodList.append(int(ts) - preTimeStamp) preTimeStamp = ts - + for x, y in self.database.items(): for i in y: if i not in self.periods: @@ -277,31 +277,30 @@ def getSortedListOfItemFrequencies(self) -> Dict[str, int]: itemFrequencies[item] = itemFrequencies.get(item, 0) itemFrequencies[item] += 1 return {k: v for k, v in sorted(itemFrequencies.items(), key=lambda x: x[1], reverse=True)} - + def getFrequenciesInRange(self) -> Dict[int, int]: fre = self.getSortedListOfItemFrequencies() rangeFrequencies = {} maximum = max([i for i in fre.values()]) - values = [int(i*maximum/6) for i in range(1,6)] - #print(maximum) + values = [int(i * maximum / 6) for i in range(1, 6)] + # print(maximum) va = len({key: val for key, val in fre.items() if val > 0 and val < values[0]}) rangeFrequencies[va] = values[0] - for i in range(1,len(values)): - - va = len({key: val for key, val in fre.items() if val < values[i] and val > values[i-1]}) + for i in range(1, len(values)): + va = len({key: val for key, val in fre.items() if val < values[i] and val > values[i - 1]}) rangeFrequencies[va] = values[i] return rangeFrequencies - + def getPeriodsInRange(self) -> Dict[int, int]: fre = {k: v for k, v in sorted(self.periods.items(), key=lambda x: x[1])} rangePeriods = {} maximum = max([i for i in fre.values()]) - values = [int(i*maximum/6) for i in range(1,6)] - #print(maximum) + values = [int(i * maximum / 6) for i in range(1, 6)] + # print(maximum) va = len({key: val for key, val in fre.items() if val > 0 and val < values[0]}) rangePeriods[va] = values[0] - for i in range(1,len(values)): - va = len({key: val for key, val in fre.items() if val < values[i] and val > values[i-1]}) + for i in range(1, len(values)): + va = len({key: val for key, val in fre.items() if val < values[i] and val > values[i - 1]}) rangePeriods[va] = values[i] return rangePeriods @@ -349,21 +348,21 @@ def getMaximumInterArrivalPeriod(self) -> int: :return: maximum inter arrival period """ return max(self.periodList) - + def getMinimumPeriodOfItem(self) -> int: """ get the minimum period of the item :return: minimum period """ return min([i for i in self.periods.values()]) - + def getAveragePeriodOfItem(self) -> float: """ get the average period of the item :return: average period """ return sum([i for i in self.periods.values()]) / len(self.periods) - + def getMaximumPeriodOfItem(self) -> int: """ get the maximum period of the item @@ -385,7 +384,7 @@ def getNumberOfTransactionsPerTimestamp(self) -> Dict[int, int]: """ maxTS = max(list(self.timeStampCount.keys())) return {ts: self.timeStampCount.get(ts, 0) for ts in range(1, maxTS + 1)} - + def printStats(self) -> None: print(f'Database size : {self.getDatabaseSize()}') print(f'Number of items : {self.getTotalNumberOfItems()}') @@ -401,7 +400,7 @@ def printStats(self) -> None: print(f'Standard Deviation Transaction Size : {self.getStandardDeviationTransactionLength()}') print(f'Variance : {self.getVarianceTransactionLength()}') print(f'Sparsity : {self.getSparsity()}') - + def plotGraphs(self) -> None: itemFrequencies = self.getFrequenciesInRange() transactionLength = self.getTransanctionalLengthDistribution() @@ -409,6 +408,7 @@ def plotGraphs(self) -> None: plt.plotLineGraphFromDictionary(transactionLength, 100, 0, 'transaction length', 'transaction length', 'frequency') + if __name__ == '__main__': data = {'tid': [1, 2, 3, 4, 5, 6, 7], diff --git a/docs/dataFrameCoversion.md b/docs/dataFrameCoversion.md index 8a1017ce..9647d501 100644 --- a/docs/dataFrameCoversion.md +++ b/docs/dataFrameCoversion.md @@ -46,7 +46,7 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli Default separator used in PAMI is tab space. However, users can override the separator with their choice. 1. [Converting Dataframes to Databases](df2db.html) - 1. [Dense dataframe to database](DenseFormatDF2DB.html) - 1. [Sparse dataframe to database](sparseFormatDF2DB.html) + 1. [Dense dataframe to database](DenseFormatDF.html) + 1. [Sparse dataframe to database](SparseFormatDF.html) 1. [Spatiotemporal dataframe to databases](stDF2DB.html) diff --git a/docs/examples.md b/docs/examples.md index 5488696c..35eb0ffe 100644 --- a/docs/examples.md +++ b/docs/examples.md @@ -84,15 +84,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli of the data in a data frame, we categorize them as a dense data frame and a sparse data frame. PAMI currently provides in-built procedures to convert these data frames into transactional and temporal databases. - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Basic approach to convert a dataframe into a database](DenseFormatDF2DB.html) + 3. [Basic approach to convert a dataframe into a database](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/exercises/fuzzyFrequentPatternMining.md b/docs/exercises/fuzzyFrequentPatternMining.md index 45978810..c57fe72c 100644 --- a/docs/exercises/fuzzyFrequentPatternMining.md +++ b/docs/exercises/fuzzyFrequentPatternMining.md @@ -84,15 +84,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli of the data in a data frame, we categorize them as a dense data frame and a sparse data frame. PAMI currently provides in-built procedures to convert these data frames into transactional and temporal databases. - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Basic approach to convert a dataframe into a database](DenseFormatDF2DB.html) + 3. [Basic approach to convert a dataframe into a database](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/exercises/peirodicFrequentPatternMining.md b/docs/exercises/peirodicFrequentPatternMining.md index 45978810..c57fe72c 100644 --- a/docs/exercises/peirodicFrequentPatternMining.md +++ b/docs/exercises/peirodicFrequentPatternMining.md @@ -84,15 +84,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli of the data in a data frame, we categorize them as a dense data frame and a sparse data frame. PAMI currently provides in-built procedures to convert these data frames into transactional and temporal databases. - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Basic approach to convert a dataframe into a database](DenseFormatDF2DB.html) + 3. [Basic approach to convert a dataframe into a database](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/index.md b/docs/index.md index a519d8d5..c5850e0f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -19,9 +19,9 @@ Chapter 2: Preparation of various datasets (or databases) Chapter 3: Converting dataframes to databases - 1. [Format of dense dataframe](./manuals/DenseFormatDF2DB.html) - 2. [Format of sparse dataframe](./manuals/sparseFormatDF2DB.html) - 3. [Approaches to convert a dataframe into various database formats](./manuals/DenseFormatDF2DB.html) + 1. [Format of dense dataframe](./manuals/DenseFormatDF.html) + 2. [Format of sparse dataframe](./manuals/SparseFormatDF.html) + 3. [Approaches to convert a dataframe into various database formats](./manuals/DenseFormatDF.html) 4. [An advanced approach to convert a dataframe into a database](./manuals/DF2DBPlus.html) Chapter 4: Creation of very large synthetic databases diff --git a/docs/index.md.bak b/docs/index.md.bak index e7017cc6..5e39adf7 100644 --- a/docs/index.md.bak +++ b/docs/index.md.bak @@ -84,15 +84,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli of the data in a data frame, we categorize them as a dense data frame and a sparse data frame. PAMI currently provides in-built procedures to convert these data frames into transactional and temporal databases. - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Basic approach to convert a dataframe into a database](DenseFormatDF2DB.html) + 3. [Basic approach to convert a dataframe into a database](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/manual.md b/docs/manual.md index c45a0b94..1d3682cd 100644 --- a/docs/manual.md +++ b/docs/manual.md @@ -189,15 +189,15 @@ get the statistical details of a database. 7. [Converting dataframes to databases](dataFrameCoversio.html) - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Dataframe to database conversion](DenseFormatDF2DB.html) + 3. [Dataframe to database conversion](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/manuals/DF2DBPlus.md b/docs/manuals/DF2DBPlus.md index 581fe7d4..1ee9b126 100644 --- a/docs/manuals/DF2DBPlus.md +++ b/docs/manuals/DF2DBPlus.md @@ -22,14 +22,14 @@ An example of a dense dataframe generated from the customer purchase database is ### Converting a sparse dataframe into different database formats Currently, PAMI supports converting a dataframe into a transactional database, temporal database, ond a utility database. -The users can avail this support by employing the methods available in **dataPreprocessign.sparseFormatDF2DB** class. +The users can avail this support by employing the methods available in **dataPreprocessign.SparseFormatDF** class. We now present these three methods. #### Converting a dense dataframe into a transactional database A [transactional database](transactionalDatabase.html) represents a sparse and binary representation of items occurring in a dataframe. The steps to convert a dataframe into a transactional database is as follows: -1. Initialize the sparseFormatDF2DB class by passing the following three parameters: +1. Initialize the SparseFormatDF class by passing the following three parameters: 1. inputDataFrame - the dataframe that needs to converted into a database 1. thresholdValue - this value will be used to convert a non-binary data frame into a binary database 1. condition - The condition that needs to employed on the threshold value. Currently, the users can specify @@ -40,12 +40,12 @@ The steps to convert a dataframe into a transactional database is as follows: A sample program to convert a dataframe into a transactional database and use it in a pattern mining algorithm, say FP-growth, is provided below ```Python -from PAMI.extras.DF2DB import SparseFormatDF2DB as pro +from PAMI.extras.DF2DB import SparseFormatDF as pro from PAMI.frequentPattern.basic import FPGrowth as alg import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.SparseFormatDF(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a transactional database file db.createTransactional(outputFile='/home/userName/transactionalDB.txt') # Getting the fileName of the transactional database @@ -63,7 +63,7 @@ patternsDF = obj.getPatternsAsDataFrame() A [temporal database](temporalDatabase.html) represents a sparse and binary representation of items occurring at a particular timestamp in a dataframe. The steps to convert a dataframe into a temporal database is as follows: -1. Initialize the sparseFormatDF2DB class by passing the following three parameters: +1. Initialize the SparseFormatDF class by passing the following three parameters: 1. inputDataFrame - the dataframe that needs to converted into a database 1. thresholdValue - this value will be used to convert a non-binary data frame into a binary database 1. condition - The condition that needs to employed on the threshold value. Currently, the users can specify @@ -74,12 +74,12 @@ in a dataframe. The steps to convert a dataframe into a temporal database is as A sample program to convert a dataframe into a temporal database and use it in a pattern mining algorithm, say PFP-growth++, is provided below ```Python - from PAMI.extras.DF2DB import SparseFormatDF2DB as pro + from PAMI.extras.DF2DB import SparseFormatDF as pro from PAMI.periodicFrequentPattern.basic import PFPGrowthPlus as alg import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.SparseFormatDF(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a transactional database file db.createTransactional(outputFile='/home/userName/temporalDB.txt') # Getting the fileName of the transactional database @@ -94,7 +94,7 @@ patternsDF = obj.getPatternsAsDataFrame() A [utility database](utilityDatabase.html) represents a sparse and non-binary representation of items occurring in each row of a dataframe. The steps to convert a dataframe into a utility database is as follows: -1. Initialize the sparseFormatDF2DB class by passing the following three parameters: +1. Initialize the SparseFormatDF class by passing the following three parameters: 1. inputDataFrame - the dataframe that needs to converted into a database 1. thresholdValue - this value will be used to convert a non-binary data frame into a binary database 1. condition - The condition that needs to employed on the threshold value. Currently, the users can specify @@ -105,12 +105,12 @@ each row of a dataframe. The steps to convert a dataframe into a utility databa A sample program to convert a dataframe into a utility database and use it in a pattern mining algorithm, say EFIM, is provided below ```Python - from PAMI.extras.DF2DB import SparseFormatDF2DB as pro + from PAMI.extras.DF2DB import SparseFormatDF as pro from PAMI.highUtilityPattern.basic import EFIM as alg import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.SparseFormatDF(inputDataFrame=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a transactional database file db.createTransactional(outputFile='/home/userName/utilityDB.txt') # Getting the fileName of the transactional database diff --git a/docs/manuals/denseDF2DB.md b/docs/manuals/denseDF2DB.md index 10f7ea5a..864d883c 100644 --- a/docs/manuals/denseDF2DB.md +++ b/docs/manuals/denseDF2DB.md @@ -20,11 +20,11 @@ The steps to convert a dataframe into a transactional database is as follows: #### Sample code ```Python -from PAMI.extras.DF2DB import DenseFormatDF2DB as pro +from PAMI.extras.DF2DB import DenseFormatDF as pro import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.DenseFormatDF2DB(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.DenseFormatDF(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a transactional database file db.createTransactional(outputFile='/home/userName/transactionalDB.txt') # Getting the fileName of the transactional database @@ -48,11 +48,11 @@ in a dataframe. The steps to convert a dataframe into a temporal database is as #### Sample code ```Python -from PAMI.extras.DF2DB import DenseFormatDF2DB as pro +from PAMI.extras.DF2DB import DenseFormatDF as pro import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.DenseFormatDF2DB(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.DenseFormatDF(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a temporal database file db.createTemporal(outputFile='/home/userName/temporalDB.txt') # Getting the fileName of the temporal database @@ -75,11 +75,11 @@ each row of a dataframe. The steps to convert a dataframe into a utility databa #### Sample code ```Python -from PAMI.extras.DF2DB import DenseFormatDF2DB as pro +from PAMI.extras.DF2DB import DenseFormatDF as pro import pandas as pd # Objective: convert the above dataframe into a utility database with items whose value is greater than or equal 1. -db = pro.DenseFormatDF2DB(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.DenseFormatDF(inputDF=pd.DataFrame('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a utility database file db.createUtility(outputFile='/home/userName/utilityDB.txt') # Getting the fileName of the utility database diff --git a/docs/manuals/index.md b/docs/manuals/index.md index cb6f00de..4907a5ee 100644 --- a/docs/manuals/index.md +++ b/docs/manuals/index.md @@ -21,7 +21,7 @@ Chapter 3: Converting dataframes to databases 1. [Format of dense dataframe](./denseDataFrame.html) 2. [Format of sparse dataframe](./sparseDataFrame.html) - 3. [Approaches to convert a dataframe into various database formats](./DenseFormatDF2DB.html) + 3. [Approaches to convert a dataframe into various database formats](./DenseFormatDF.html) 4. [An advanced approach to convert a dataframe into a database](./DF2DBPlus.html) Chapter 4: Creation of very large synthetic databases @@ -32,7 +32,7 @@ Chapter 4: Creation of very large synthetic databases Chapter 5: Printing, displaying, and saving the statistical details of a database - 1. [Transactional databases](./transactionalDatabaseStats.html) + 1. [Transactional databases](./TransactionalDatabase.html) 2. [Temporal database (partially under development)](./temporalDatabaseStats.html) 3. [Utility database (partially under development)](./utilityDatabaseStats.html) 4. [Uncertain database (under development)](./uncertainDatabaseStats.html) diff --git a/docs/manuals/sparseDF2DB.md b/docs/manuals/sparseDF2DB.md index c219a0e4..b1165531 100644 --- a/docs/manuals/sparseDF2DB.md +++ b/docs/manuals/sparseDF2DB.md @@ -2,7 +2,7 @@ ## Converting a sparse dataframe into different database formats Currently, PAMI supports converting a dataframe into a transactional database, temporal database, ond a utility database. -The users can avail this support by employing the methods available in **dataPreprocessign.sparseFormatDF2DB** class. +The users can avail this support by employing the methods available in **dataPreprocessign.SparseFormatDF** class. We now present these three methods. ### Sparse dataframe into a transactional database @@ -10,7 +10,7 @@ We now present these three methods. A [transactional database](transactionalDatabase.html) represents a sparse and binary representation of items occurring in a dataframe. The steps to convert a dataframe into a transactional database is as follows: -1. Initialize the sparseFormatDF2DB class by passing the following three parameters: +1. Initialize the SparseFormatDF class by passing the following three parameters: 1. inputDataFrame - the dataframe that needs to converted into a database 1. thresholdValue - this value will be used to convert a non-binary data frame into a binary database 1. condition - The condition that needs to employed on the threshold value. Currently, the users can specify @@ -21,11 +21,11 @@ The steps to convert a dataframe into a transactional database is as follows: #### Sample code ```Python -from PAMI.extras.DF2DB import SparseFormatDF2DB as pro +from PAMI.extras.DF2DB import SparseFormatDF as pro import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDF=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.SparseFormatDF(inputDF=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a transactional database file db.createTransactionalDatabase(outputFile='/home/userName/transactionalDB.txt') # Getting the fileName of the transactional database @@ -39,7 +39,7 @@ print('The output file is saved at ' + db.getFileName()) A [temporal database](temporalDatabase.html) represents a sparse and binary representation of items occurring at a particular timestamp in a dataframe. The steps to convert a dataframe into a temporal database is as follows: -1. Initialize the sparseFormatDF2DB class by passing the following three parameters: +1. Initialize the SparseFormatDF class by passing the following three parameters: 1. inputDataFrame - the dataframe that needs to converted into a database 1. thresholdValue - this value will be used to convert a non-binary data frame into a binary database 1. condition - The condition that needs to employed on the threshold value. Currently, the users can specify @@ -50,12 +50,12 @@ in a dataframe. The steps to convert a dataframe into a temporal database is as #### Sample code ```Python -from PAMI.extras.DF2DB import SparseFormatDF2DB as pro +from PAMI.extras.DF2DB import SparseFormatDF as pro from PAMI.periodicFrequentPattern.basic import PFPGrowthPlus as alg import pandas as pd # Objective: convert the above dataframe into a transactional database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDataFrame=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') +db = pro.SparseFormatDF(inputDataFrame=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') # Convert and store the dataframe as a temporal database file db.createTemporalDatabase(outputFile='/home/userName/temporalDB.txt') # Getting the fileName of the temporal database @@ -91,7 +91,7 @@ database is as follows: 1. Initialize the -sparseFormatDF2DB +SparseFormatDF class by passing the following three parameters: @@ -140,30 +140,29 @@ class by passing the following three parameters: six constraints: >, >=, <, <=, ==, and !=. - -1. -Call -'createUtility(outputFileName)' -method -to -store -the -dataframe as a -temporal -database. - -#### Sample code - -```Python -from PAMI.extras.DF2DB import SparseFormatDF2DB as pro -from PAMI.highUtilityPattern.basic import EFIM as alg -import pandas as pd - -# Objective: convert the above dataframe into a utility database with items whose value is greater than or equal 1. -db = pro.sparseFormatDF2DB(inputDataFrame=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') -# Convert and store the dataframe as a utility database file -db.createUtilityDatabase(outputFile='/home/userName/utilityDB.txt') -# Getting the fileName of the utility database -print('The output file is saved at ' + db.getFileName()) + 1. + Call + 'createUtility(outputFileName)' + method + to + store + the + dataframe as a + temporal + database. + + #### Sample code + + ```Python + from PAMI.extras.DF2DB import SparseFormatDF as pro + from PAMI.highUtilityPattern.basic import EFIM as alg + import pandas as pd + + # Objective: convert the above dataframe into a utility database with items whose value is greater than or equal 1. + db = pro.SparseFormatDF(inputDataFrame=pd.read_csv('mentionDataFrame'), thresholdValue=1, condition='>=') + # Convert and store the dataframe as a utility database file + db.createUtilityDatabase(outputFile='/home/userName/utilityDB.txt') + # Getting the fileName of the utility database + print('The output file is saved at ' + db.getFileName()) ``` diff --git a/docs/manuals/terminalExecute.md b/docs/manuals/terminalExecute.md index 93bcab75..f4fe8551 100644 --- a/docs/manuals/terminalExecute.md +++ b/docs/manuals/terminalExecute.md @@ -86,15 +86,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli 6. [Converting dataframes to databases](dataFrameCoversio.html) - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Dataframe to database conversion](DenseFormatDF2DB.html) + 3. [Dataframe to database conversion](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/plotItemFrequencies.md b/docs/plotItemFrequencies.md index 5d5d09e5..fa772d69 100644 --- a/docs/plotItemFrequencies.md +++ b/docs/plotItemFrequencies.md @@ -164,15 +164,15 @@ get the statistical details of a database. 7. [Converting dataframes to databases](dataFrameCoversio.html) - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Dataframe to database conversion](DenseFormatDF2DB.html) + 3. [Dataframe to database conversion](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/plotTransactionDistribution.md b/docs/plotTransactionDistribution.md index 5d5d09e5..fa772d69 100644 --- a/docs/plotTransactionDistribution.md +++ b/docs/plotTransactionDistribution.md @@ -164,15 +164,15 @@ get the statistical details of a database. 7. [Converting dataframes to databases](dataFrameCoversio.html) - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Dataframe to database conversion](DenseFormatDF2DB.html) + 3. [Dataframe to database conversion](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/docs/useAlgo.md b/docs/useAlgo.md index 72b01bbc..de971e60 100644 --- a/docs/useAlgo.md +++ b/docs/useAlgo.md @@ -86,15 +86,15 @@ Key concepts in each link were briefly mentioned to save your valuable time. Cli 6. [Converting dataframes to databases](dataFrameCoversio.html) - 1. [Format of dense dataframe]((DenseFormatDF2DB.html)) + 1. [Format of dense dataframe]((DenseFormatDF.html)) tid/timestampitem1item2...itemN - 2. [Format of sparse dataframe]((sparseFormatDF2DB.html)) + 2. [Format of sparse dataframe]((SparseFormatDF.html)) tid/timestampitemvalue - 3. [Dataframe to database conversion](DenseFormatDF2DB.html) + 3. [Dataframe to database conversion](DenseFormatDF.html) This program creates a database by specifying a single condition and a threshold value for all items in a database. Code to convert a dataframe into a transactional database: diff --git a/htmlDocs/PAMI.extras.DF2DB.rst b/htmlDocs/PAMI.extras.DF2DB.rst index 33d13d66..cf732420 100644 --- a/htmlDocs/PAMI.extras.DF2DB.rst +++ b/htmlDocs/PAMI.extras.DF2DB.rst @@ -28,34 +28,34 @@ PAMI.extras.DF2DB.createTDB module :undoc-members: :show-inheritance: -PAMI.extras.DF2DB.DenseFormatDF2DB module +PAMI.extras.DF2DB.DenseFormatDF module ----------------------------------- -.. automodule:: PAMI.extras.DF2DB.DenseFormatDF2DB +.. automodule:: PAMI.extras.DF2DB.DenseFormatDF :members: :undoc-members: :show-inheritance: -PAMI.extras.DF2DB.DenseFormatDF2DBPlus module +PAMI.extras.DF2DB.DenseFormatDFPlus module --------------------------------------- -.. automodule:: PAMI.extras.DF2DB.DenseFormatDF2DBPlus +.. automodule:: PAMI.extras.DF2DB.DenseFormatDFPlus :members: :undoc-members: :show-inheritance: -PAMI.extras.DF2DB.sparseFormatDF2DB module +PAMI.extras.DF2DB.SparseFormatDF module ------------------------------------ -.. automodule:: PAMI.extras.DF2DB.sparseFormatDF2DB +.. automodule:: PAMI.extras.DF2DB.SparseFormatDF :members: :undoc-members: :show-inheritance: -PAMI.extras.DF2DB.sparseFormatDF2DBPlus module +PAMI.extras.DF2DB.SparseFormatDFPlus module ---------------------------------------- -.. automodule:: PAMI.extras.DF2DB.sparseFormatDF2DBPlus +.. automodule:: PAMI.extras.DF2DB.SparseFormatDFPlus :members: :undoc-members: :show-inheritance: diff --git a/htmlDocs/_build/html/PAMI.extras.DF2DB.html b/htmlDocs/_build/html/PAMI.extras.DF2DB.html index ae03cf9c..60df24cd 100644 --- a/htmlDocs/_build/html/PAMI.extras.DF2DB.html +++ b/htmlDocs/_build/html/PAMI.extras.DF2DB.html @@ -256,11 +256,11 @@

Importing this algorithm into a python program -

PAMI.extras.DF2DB.DenseFormatDF2DB module

+
+

PAMI.extras.DF2DB.DenseFormatDF module

-
-class PAMI.extras.DF2DB.DenseFormatDF2DB.DenseFormatDF2DB(inputDF, condition: str, thresholdValue: int | float)[source]
+
+class PAMI.extras.DF2DB.DenseFormatDF.DenseFormatDF(inputDF, condition: str, thresholdValue: int | float)[source]

Bases: object

Description:
@@ -282,8 +282,8 @@

Importing this algorithm into a python program

 
-

from PAMI.extras.DF2DB import DenseFormatDF2DB as db

-

obj = db.DenseFormatDF2DB(iDdf, ">=", 16 )

+

from PAMI.extras.DF2DB import DenseFormatDF as db

+

obj = db.DenseFormatDF(iDdf, ">=", 16 )

obj.save(oFile)

obj.createTransactional("outputFileName") # To create transactional database

obj.createTemporal("outputFileName") # To create temporal database

@@ -291,8 +291,8 @@

Importing this algorithm into a python program -
-createMultipleTimeSeries(interval: int, outputFile: str) None[source]
+
+createMultipleTimeSeries(interval: int, outputFile: str) None[source]
Description:

Create the multiple time series data base.

@@ -305,8 +305,8 @@

Importing this algorithm into a python program -
-createTemporal(outputFile: str) None[source]
+
+createTemporal(outputFile: str) None[source]
Description:

Create temporal data base

@@ -319,8 +319,8 @@

Importing this algorithm into a python program -
-createTransactional(outputFile: str) None[source]
+
+createTransactional(outputFile: str) None[source]
Description:

Create transactional data base

@@ -333,8 +333,8 @@

Importing this algorithm into a python program -
-createUtility(outputFile: str) None[source]
+
+createUtility(outputFile: str) None[source]
Description:

Create the utility database.

@@ -347,8 +347,8 @@

Importing this algorithm into a python program -
-getFileName() str[source]
+
+getFileName() str[source]
Returns:

outputFile name

@@ -360,11 +360,11 @@

Importing this algorithm into a python program -

PAMI.extras.DF2DB.DenseFormatDF2DBPlus module

+
+

PAMI.extras.DF2DB.DenseFormatDFPlus module

-
-class PAMI.extras.DF2DB.DenseFormatDF2DBPlus.DenseFormatDF2DBPlus(inputDF, thresholdConditionDF)[source]
+
+class PAMI.extras.DF2DB.DenseFormatDFPlus.DenseFormatDFPlus(inputDF, thresholdConditionDF)[source]

Bases: object

Description:
@@ -384,16 +384,16 @@

Importing this algorithm into a python program

 
-

from PAMI.extras.DF2DB import DenseFormatDF2DBPlus as db

-

obj = db.DenseFormatDF2DBPlus(iDdf, ">=", 16)

+

from PAMI.extras.DF2DB import DenseFormatDFPlus as db

+

obj = db.DenseFormatDFPlus(iDdf, ">=", 16)

obj.save(oFile)

obj.createTransactional("outputFileName") # To create transactional database

obj.createTemporal("outputFileName") # To create temporal database

obj.createUtility("outputFileName") # To create utility database

obj.getFileName("outputFileName") # To get file name of the database

-
-createTemporal(outputFile: str) None[source]
+
+createTemporal(outputFile: str) None[source]

Create temporal data base

Parameters:
@@ -403,8 +403,8 @@

Importing this algorithm into a python program -
-createTransactional(outputFile: str) None[source]
+
+createTransactional(outputFile: str) None[source]

Create transactional data base

Parameters:
@@ -414,8 +414,8 @@

Importing this algorithm into a python program -
-createUtility(outputFile: str) None[source]
+
+createUtility(outputFile: str) None[source]

Create the utility data base.

Parameters:
@@ -425,8 +425,8 @@

Importing this algorithm into a python program -
-getFileName() str[source]
+
+getFileName() str[source]
Returns:

outputFile name

@@ -438,10 +438,10 @@

Importing this algorithm into a python program -

PAMI.extras.DF2DB.sparseFormatDF2DB module

+
+

PAMI.extras.DF2DB.SparseFormatDF module

-
+
class PAMI.extras.DF2DB.sparseDF2DB.sparseDF2DB(inputDF, condition: str, thresholdValue: float)[source]

Bases: object

diff --git a/htmlDocs/_build/html/PAMI.extras.dbStats.html b/htmlDocs/_build/html/PAMI.extras.dbStats.html index ab79e9b1..df9794f3 100644 --- a/htmlDocs/_build/html/PAMI.extras.dbStats.html +++ b/htmlDocs/_build/html/PAMI.extras.dbStats.html @@ -345,16 +345,16 @@

Importing this algorithm into a python program -

PAMI.extras.dbStats.TemporalDatabase module

+
+

PAMI.extras.dbStats.temporalDatabaseStats module

-
-class PAMI.extras.dbStats.TemporalDatabase.TemporalDatabase(inputFile: str | DataFrame, sep: str = '\t')[source]
+
+class PAMI.extras.dbStats.temporalDatabaseStats.temporalDatabaseStats(inputFile: str | DataFrame, sep: str = '\t')[source]

Bases: object

Description:

-

TemporalDatabase is class to get stats of database.

+

temporalDatabaseStats is class to get stats of database.

@@ -409,7 +409,7 @@

Methods:

-
+
convertDataIntoMatrix() ndarray[source]
@@ -592,8 +592,8 @@

Methods:

-
-

PAMI.extras.dbStats.TransactionalDatabase module

+
+

PAMI.extras.dbStats.transactionalDatabaseStats module

class PAMI.extras.dbStats.transactionalDatabaseStats.transactionalDatabaseStats(inputFile: str | DataFrame, sep: str = '\t')[source]
@@ -1200,7 +1200,7 @@

Importing this algorithm into a python program -

PAMI.extras.dbStats.UtilityDatabase module

+

PAMI.extras.dbStats.utilityDatabaseStats module

Module contents

diff --git a/htmlDocs/_build/html/PAMI.extras.html b/htmlDocs/_build/html/PAMI.extras.html index c1cdfd5e..19ee70f5 100644 --- a/htmlDocs/_build/html/PAMI.extras.html +++ b/htmlDocs/_build/html/PAMI.extras.html @@ -144,32 +144,32 @@

SubpackagesPAMI.extras.DF2DB.DenseFormatDF2DB module