This repository contains supplementary data and MATLAB code for "Mechanism Design for Decentralized Peer-to-Peer Energy Trading Considering Heterogeneous Preferences" by Saber Talari, Mohsen Khorasany, Reza Razzaghi, Wolfgang Ketter, and Amin Shokri Gazafroudi. The main code is named as "decentralizedptp" and takes "sellers" and "buyers" input data as csv files and generates the results of a decentralized p2p trading between sellers and buyers.