beatlestribute 0.0.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
Copyright © 2024 Carla Sónia Godinho
|
|
3
|
+
|
|
4
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
5
|
+
|
|
6
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
7
|
+
|
|
8
|
+
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: beatlestribute
|
|
3
|
+
Version: 0.0.6
|
|
4
|
+
Summary: Shows a list of The Beatles albuns, stats and the band members. Show Dataframe info. Use Help.
|
|
5
|
+
Author-email: Carla Godinho <carlagodinho.it@gmail.com>
|
|
6
|
+
License-File: LICENSE.txt
|
|
7
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
8
|
+
Classifier: Operating System :: OS Independent
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Requires-Python: >=3.12
|
|
11
|
+
Description-Content-Type: text/markdown
|
|
12
|
+
|
|
13
|
+
# beatlestribute
|
|
14
|
+
==========
|
|
15
|
+
This package is a demo for my Python students and so I decided to give a tribute to The Beatles band, providing a list of their published Albums.
|
|
16
|
+
Enjoy this packge and listen to their masterpieces!
|
|
17
|
+
|
|
18
|
+
NOTE:
|
|
19
|
+
----------
|
|
20
|
+
To use this beatlestribute module it is mandatory to install pandas module (Tested with version 2.2.2.) Intall pandas module:
|
|
21
|
+
|
|
22
|
+
console> pip install pandas
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
Change log
|
|
26
|
+
------------
|
|
27
|
+
0.0.1 - Show Abuns, band and dataframe statistics
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# beatlestribute
|
|
2
|
+
==========
|
|
3
|
+
This package is a demo for my Python students and so I decided to give a tribute to The Beatles band, providing a list of their published Albums.
|
|
4
|
+
Enjoy this packge and listen to their masterpieces!
|
|
5
|
+
|
|
6
|
+
NOTE:
|
|
7
|
+
----------
|
|
8
|
+
To use this beatlestribute module it is mandatory to install pandas module (Tested with version 2.2.2.) Intall pandas module:
|
|
9
|
+
|
|
10
|
+
console> pip install pandas
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
Change log
|
|
14
|
+
------------
|
|
15
|
+
0.0.1 - Show Abuns, band and dataframe statistics
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# beatlestribute
|
|
2
|
+
==========
|
|
3
|
+
This package is a demo for my Python students and so I decided to give a tribute to The Beatles band, providing a list of their published Albums.
|
|
4
|
+
Enjoy this packge and listen to their masterpieces!
|
|
5
|
+
|
|
6
|
+
NOTE:
|
|
7
|
+
----------
|
|
8
|
+
To use this beatlestribute module it is mandatory to install pandas module (Tested with version 2.2.2.) Intall pandas module:
|
|
9
|
+
|
|
10
|
+
console> pip install pandas
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
Change log
|
|
14
|
+
------------
|
|
15
|
+
0.0.1 - Show Abuns, band and dataframe statistics
|
|
File without changes
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import pandas as pd
|
|
2
|
+
|
|
3
|
+
class BAlbuns:
|
|
4
|
+
""" Classe que apresenta algumas curiosidades sobre os Beatles
|
|
5
|
+
Para utilizar este módulo não se esqueça de instalar o pandas
|
|
6
|
+
Ex:
|
|
7
|
+
import beatlestribute as ba
|
|
8
|
+
lista_albuns = ba.BAlbuns() # instaciação do objeto tipo BAlbuns
|
|
9
|
+
lista_albuns.show_albuns() # Pedir lista de albuns
|
|
10
|
+
lista_albuns.info() # Pedir lista informações do Dataframe que tem a lista dos albuns
|
|
11
|
+
Ex: para chamar o Help
|
|
12
|
+
help(show_albuns) # Help I need somebody!! Help :-)
|
|
13
|
+
"""
|
|
14
|
+
def __init__(self):
|
|
15
|
+
#Criação de dicionário com a lista de Albuns dos Beatles
|
|
16
|
+
self.balbums={'Name': ['1-Please Please Me',
|
|
17
|
+
'2-With The Beatles',
|
|
18
|
+
'3-A Hard Day\'s Night',
|
|
19
|
+
'4-Beatles for Sale',
|
|
20
|
+
'5-Help!',
|
|
21
|
+
'6-Rubber Soul',
|
|
22
|
+
'7-Revolver',
|
|
23
|
+
'8-Sgt. Pepper\'s Lonely Hearts Club Band',
|
|
24
|
+
'9-Magical Mystery Tour',
|
|
25
|
+
'10-White Album',
|
|
26
|
+
'11-Yellow Submarine',
|
|
27
|
+
'12-Abbey Road',
|
|
28
|
+
'13-Let It Be'],
|
|
29
|
+
'Year': [1963, 1963, 1964, 1964, 1965, 1965, 1966, 1967, 1967, 1968, 1969, 1969, 1970]}
|
|
30
|
+
# Método que mostra num dataframe os albuns do grupo The Beatles
|
|
31
|
+
def show_albuns(self):
|
|
32
|
+
#Converter dicionário numa Dataframe em Pandas
|
|
33
|
+
print(f"=== Welcome! This is the list of The Beatles's albums ===".center(50))
|
|
34
|
+
print(f"=== I love The Beatles!! Yeh Yeh Yeh ===\n".center(50))
|
|
35
|
+
#print(pd.DataFrame(self.balbums))
|
|
36
|
+
return pd.DataFrame(self.balbums)
|
|
37
|
+
# Método que mostra as estatísticas da lista de albuns, contam quanto albuns/ano
|
|
38
|
+
def stats(self):
|
|
39
|
+
print("Number of albuns per year")
|
|
40
|
+
print(self.show_albuns().groupby("Year").count())
|
|
41
|
+
# Método que apresenta os nome dos elementos da banda
|
|
42
|
+
def band_members(self):
|
|
43
|
+
print("""
|
|
44
|
+
== Band Members ==
|
|
45
|
+
Vocals and Bass - Paul McCartney
|
|
46
|
+
Vocals and Guitar - John Lennon
|
|
47
|
+
Guitar - George Harrison
|
|
48
|
+
Drums - Ringo Starr
|
|
49
|
+
\n""")
|
|
50
|
+
def info(self):
|
|
51
|
+
""" Função que mostra informação do Dataframe utilizado
|
|
52
|
+
para conter a lista de albuns"""
|
|
53
|
+
return self.show_albuns().info()
|
|
54
|
+
|
|
55
|
+
#Só no caso de correr como programa principal este módulo
|
|
56
|
+
if __name__ == '__main__':
|
|
57
|
+
#Instancia um objeto do tipo classe BAlbuns do módulo
|
|
58
|
+
ls_albuns = BAlbuns()
|
|
59
|
+
#invoca os métodos show_albuns(), stats(), band_members()
|
|
60
|
+
print(ls_albuns.show_albuns())
|
|
61
|
+
ls_albuns.band_members()
|
|
62
|
+
ls_albuns.stats()
|
|
63
|
+
ls_albuns.info()
|
|
64
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "beatlestribute"
|
|
7
|
+
version = "0.0.6"
|
|
8
|
+
authors = [
|
|
9
|
+
{ name="Carla Godinho", email="carlagodinho.it@gmail.com" },
|
|
10
|
+
]
|
|
11
|
+
description = "Shows a list of The Beatles albuns, stats and the band members. Show Dataframe info. Use Help."
|
|
12
|
+
readme = "README.md"
|
|
13
|
+
requires-python = ">=3.12"
|
|
14
|
+
classifiers = [
|
|
15
|
+
"Programming Language :: Python :: 3",
|
|
16
|
+
"License :: OSI Approved :: MIT License",
|
|
17
|
+
"Operating System :: OS Independent",
|
|
18
|
+
]
|